1
votes

I've been provided a Dbase file (.dbf) and have been asked to implement a parser to load the data into an Oracle DB. The only available tools I have on hand are Java 8 and Oracle PL/SQL. Having never written a parser or dealt with this data format before, I'm completely lost as to how to go about the whole thing. Any help or guidance would be most appreciated.
Thank you,

1
See if you can find a JDBC driver for dBase.Bob Jarvis - Reinstate Monica
Is this a one off process or are you going to be provided this file on a regular basis for processing? If it is a one off then Microsoft Access is able to import from a .dbf file. I know you said you only had Java and Oracle but people often overlook access, once in a access format you can then export to CSV or use a JDBC connection for access (might be easier to find than one for dBase).Shaun Peterson
@ShaunPeterson This is going to be part of a regular load, I'm afraid. We're going to be provided a DBase file on a daily basis, and we'll have to load the data into a staging table on Oracle for further processing.Debojit
OK I have no experience doing this myself.... But my usual goto location for anything like this is asktom. oracle.com.... He has an example based in oracle 8, but by the looks of it people have contributed updated version for newer versions of oracle. Can not testify to how good this is (hence not putting it down as an answer).... but asktom.oracle.com/pls/asktom/… may give you a good start.Shaun Peterson
I had a look at that one, actually. It runs without an error, but the results are blank, as in it can read the file, but not parse it. I'm going through it again now, but this looks like it'll take some time to make sense. I was just hoping that there would've been a better solution in the last 19 years :)Debojit

1 Answers

0
votes

After tearing my hair out for some time, I think I've finally found an answer. Seemed a little crass to answer my question myself, so I posted it here: https://stackoverflow.com/a/56303353/1148258

Hope it helps anyone else looking for similar answers.