This is the successor to the XBaseToPg project for converting XBase/FoxPro files to PostgreSQL. While XBaseToPg works well, it's comparatively slow and big and complicated. The smallest changes touched lots of files, and the scope of the project is far larger than I actually needed on a daily basis.
Thus, PgDBF. It's a small C project comprising two files with no dependencies other than standard Unix libraries. While the project is relatively tiny and simple, it's also heavily optimized via profiling. I routinely got benchmark results that were many times faster than with XBaseToPg. In fact, even on slower systems, conversions were typically limited by hard drive speed.
Features
PgDBF was designed with a few core principles:
- Simplicity. This code should be understandable by anyone who wants to hack it.
- Robustness. Every syscall is checked for success.
- Speed. I wanted the fastest conversion available anywhere.
- Completeness. It has full support for FoxPro memo files.