What Are the Types of JDBC Drivers?

Today, there are five types of JDBC drivers in use:

  • Type 1: JDBC-ODBC bridge
  • Type 2: partial Java driver
  • Type 3: pure Java driver for database middleware
  • Type 4: pure Java driver for direct-to-database
  • Type 5: highly-functional drivers with superior performance

For most applications, the best choice is a pure Java driver, either Type 3, Type 4, or even Type 5.

Type 5 drivers (such as DataDirect JDBC drivers) offer advanced functionality and superior performance over other driver types.

Type 4 Drivers are the most common and are designed for a particular vendor's database.

In contrast, a Type 3 driver is a single JDBC driver used to access a middleware server, which, in turn, makes the relevant calls to the database. A good example of Type 3 JDBC driver is the DataDirect SequeLink JDBC driver.

Type 1 drivers are used for testing JDBC applications against an ODBC data source. Type 2 drivers require a native database API to be used. Both Type 1 and Type 2 mix a Java-based API with another API.

The following figure shows a side-by-side comparison of the implementation of each JDBC driver type. All four implementations show a Java application or applet using the JDBC API to communicate through the JDBC Driver Manager with a specific JDBC driver.


JDBC_Drivers_graphic-02 (1)


See the JDBC Overview page on the Oracle web site for details about the four types of JDBC drivers.

Related Solutions  | DataDirect | JDBC


DataDirect JDBC Connectors

Connect to your application with enterprise level JDBC connectivity