Search code examples
rdbaseparadox

Read dBase / Paradox data into R?


I have a hundred or so database files I inherited that I'm currently reading with "Paradox dBase Access Reader", and exporting manually to pipe-delimited text files. I'd LOVE to do this with some kind of access library that would let me read these files directly into R.

The reader tool states that these files are "Paradox 5.0 for Windows", and they have a .db extension on them.

I was hopeful that I could use the foreign package to read them, because it states in the docs for the read.dbf() function:

DBF is the extension used for files written for the ‘XBASE’ family of database languages, covering the dBase, Clipper, FoxPro, and their Windows equivalents Visual dBase, Visual Objects, and Visual FoxPro, plus some older products’

Unfortunately, it fails in the DBFOpen C function, at around line 425:

if( fread( pabyBuf, nHeadLen-32, 1, psDBF->fp ) != 1 )
{
  fclose( psDBF->fp );
  free( pabyBuf );
  free( psDBF );
  return NULL;
}

Anyone have other solutions, or insight into whether read.dbf() is a good or bad match here?


Solution

  • A search for "paradox db" on rseek.org yields the gnumeric package, which says it can read Paradox files. I don't have any way to test that functionality, but it just might work...