Use embedded SQLJ support
WAS v5.0.1 introduces support for SQLJ with the DB2 universal Java Database Connectivity (JDBC) driver provider and the DB2 Legacy CLI-based Type 2 JDBC driver for DB2 Version 8 FixPak1 (FP1).
Only the WebSphere Application Server V5.1 data source supports the DB2 universal JDBC driver provider. The WAS Version 4.0.x data source does not support this driver provider. In addition, the universal JDBC driver currently only supports a single phase data source.
Perform the following steps to convert existing JDBC applications to SQLJ in WebSphere Application Server:
- Acquire the required drivers to run SQLJ.
- DB2 Legacy CLI-based JDBC driver
You must have the db2java.zip and db2jcc.jar files in your classpath. Define these files in the classpath of the Websphere Application Server V5.1 DB2 Legacy CLI-based JDBC Driver Provider.
- DB2 Universal JDBC driver
You only need the db2jcc.jar file.
- WAS driver
WAS must be at the V5.1 level.
- Review the appropriate task file for instructions on using SQLJ with either Enterprise Java Bean (EJB) Container Managed Persistence (CMP) beans, or with EJB Bean Managed Persistence (BMP) entity beans, session beans, and servlets.
See AlsoEmbedded SQLJ support