
JDBC 4.0 support in IBM's DB2 UDB
IBM Data Server Driver for JDBC and SQLJ Version 4.0 supports the JDBC 4.0 specification. To use the JDBC 4.0 features, add the db2jcc4.jar
file to the CLASSPATH
environment variable. The JDBC 4.0 driver name is,"IBM Data Server Driver for JDBC and SQLJ" instead of the previous, "IBM DB2 JDBC Universal Driver Architecture". IBM Data Server Driver for JDBC and SQLJ supports most of the JDBC 4.0 features.
JDBC support has been added for the JDBC 4.0 java.sql.RowId
interface for updating and retrieving data in ROWID
columns. JDBC support has also been added for the java.sql.SQLXML
interface for storing, updating, and retrieving data in XML columns. The IBM Data Server Driver for JDBC and SQLJ supports the following client info properties to identify the client connections:
- ApplicationName
- ClientAccountingInformation
- ClientHostname
- ClientUser
IBM Data Server Driver for JDBC and SQLJ supports the new SQLException
subclasses, in the JDBC 4.0 specification. It also supports chained exceptions. The wrapper pattern is supported to access vendor-specific resources. The following IBM Data Server Driver for JDBC and SQLJ-specific interfaces in the com.ibm.db2.jcc
package extend the Wrapper
interface:
- DB2Connection
- DB2BaseDataSource
- DB2SimpleDataSource
- DB2Statement
- DB2ResultSet
- DB2DatabaseMetaData