libdbi implements a database-independent abstraction layer in C, similar to the DBI/DBD layer in Perl. Writing one generic set of code, programmers can leverage the power of multiple databases and multiple simultaneous database connections by using this framework.
I also created 3 ports for libdbi drivers: pgsql, mysql and sqlite3. All 4 ports are wrapped into one tarball at: http://nedbsd.nl/~wijnand/ports/libdbi.tar.gz Wijnand
