The ODBC Driver
An ODBC driver is a code component that implements the functions in the ODBC API. Each driver is specific to a particular database type. Drivers expose the capabilities of the underlying database management system (DBMS) but do not, in general, enhance its capabilities. The main exception is that drivers for DBMSs that do not have standalone database engines, as is the case with dBASE, Xbase, and ASCII text, for example, must implement a database engine that supports a minimal amount of SQL.
In particular, an ODBC driver must implement the following tasks (among others):
Connecting to and disconnecting from the data source.
Sending data to and retrieving data from the data source.
Checking for API function errors that are not checked by the Driver Manager.
Submitting SQL statements to the data source for execution. For this, the driver may need to modify the ODBC-style SQL statements to a form of SQL that the DBMS understands.
Driver Types
In general, there are two types of ODBC drivers. A file-based driver accesses the physical data in the database directly. Thus, it must process not only ODBC function calls, but also SQL statements. Put another way, a file-based driver must also be a database engine that can process ODBC SQL (at a minimum). For example, dBASE drivers are file-based drivers because dBASE does not provide a standalone database engine the driver can use.
By contrast, a DBMS-based driver accesses the physical data only through a separate database engine. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access