The DB2® product includes support for two types of JDBC driver architecture.
Driver name | Packaged as | Driver type |
---|---|---|
DB2 JDBC Type 2 Driver for Linux, UNIX and Windows | db2java.zip | Type 2 |
IBM® Data Server Driver for JDBC and SQLJ |
|
Type 2 and Type 4 |
The IBM Data Server Driver for JDBC and SQLJ is a single driver that includes JDBC type 2 and JDBC type 4 behavior. When an application loads the IBM Data Server Driver for JDBC and SQLJ, a single driver instance is loaded for type 2 and type 4 implementations. The application can make type 2 and type 4 connections using this single driver instance. The type 2 and type 4 connections can be made concurrently. IBM Data Server Driver for JDBC and SQLJ type 2 driver behavior is referred to as IBM Data Server Driver for JDBC and SQLJ type 2 connectivity. IBM Data Server Driver for JDBC and SQLJ type 4 driver behavior is referred to as IBM Data Server Driver for JDBC and SQLJ type 4 connectivity.
Two versions of the IBM Data Server Driver for JDBC and SQLJ are available. IBM Data Server Driver for JDBC and SQLJ version 3.5x is JDBC 3.0-compliant. IBM Data Server Driver for JDBC and SQLJ version 4.x is compliant with JDBC 4.0 or later.
The IBM Data Server Driver for JDBC and SQLJ is the default driver for Java routines.
The DB2 JDBC type 2 driver lets Java applications make calls to DB2 through JDBC. Calls to the DB2 JDBC type 2 driver are implemented with Java native methods. The DB2 JDBC Type 2 Driver uses the DB2 CLI interface to communicate with DB2 data servers. The Java applications that use this driver must run on a DB2 client, through which JDBC requests flow to the DB2 data server. DB2 Connect™ must be installed before the DB2 JDBC application driver can be used to access DB2 for i data sources or data sources in the DB2 for z/OS® environments.
The DB2 JDBC Type 2 Driver for Linux, UNIX and Windows will not be supported in future releases. You should therefore consider moving to the IBM Data Server Driver for JDBC and SQLJ.