Dbc
This library is out of date. Since I've updated this web page, I've
upgraded several versions of Linux and g++. I've continued to update
dbc, but have not made it public. Current version uses unixODBC
and PostgreSQL. Oracle support is probably stale; I havn't used it
in ages. Drop me a line if you're interested in the latest code. Now
back to old, out-of-date html...
Dbc is a portable, extendable database access class library
which currently supports Oracle8 OCI and ODBC. I have attempted
to make the library as easy to use as possible, while remaining
flexible and fast. The library allows portablility but does not
enforce it; it makes no attempt to prevent usage of database
specific functionality.
All development is being done on Linux (RH5.1) with Egcs 1.1.
The code uses C++ exceptions, STL and templates, so older
compilers will have problems. Egcs 1.0 may work, although I've
had trouble with it's exception support. g++ 2.7.x will not
work.
Dbc...
- Supports Oracle 8 OCI and ODBC. OCI has been tested with
the recently released Oracle 8 for Linux. ODBC support has been
tested with Solid Server
and MySQL (using iODBC).
- Supports array fetches.
- Supports array inserts/updates (OCI only).
- Seems to be pretty fast and simple to use.
Applications
Well, there's one anyway. Take a look.
Availability
Dbc is being made available under the terms of the GNU Library
General Public License.
You can download libdbc from here (85K).
You can look at the doxygen generated
documentation here.
To build you will find tmake helpful.
Notes for v0.4
To build:
-
Currently OCI and ODBC support are compiled in. You will need
Oracle 8 with current patches and Solid Server if you want
to use both. Modify libdbcimpl.h if you would like to
eliminate support for either.
-
If you would like to use MySQL instead of Solid Server, you
will have to tweak odbchdr.h to cause the MySQL includes to be
compiled in rather than the Solid Server includes. If you want to
try to add support for another ODBC library, all you should
have to do is add the headers to odbchdr.h.
-
Modify the tmake template libdbc.pro. The INCLUDEPATH
variable will have to be set appropriately on your system. By
default it is set to the locations of the Solid and Oracle
header files on my system. It is not necessary to compile
against both; either can be used, or you can attempt another
ODBC library. When you're done modifying libdbc.pro,
regenerate the makefile by running 'tmake -o Makefile
libdbc.pro'. If you do not have tmake, you will have to edit
the Makefile manually (or you can download tmake from this site).
To install:
Copy the libraries to your favorite local library spot
(/usr/local/lib perhaps) and copy dbc*.h to your favorite local
include spot.
Feedback
Feedback is welcome. If you find Dbc useful (or lacking) please let me know.
Kelly Burkhart
Last modified: Sun Jan 28 07:59:05 CST 2007