Before you create a JDBC or upload subscription that uses a non-DB2 JDBC driver, you need to configure the Sync Server. This usually includes adding the JDBC driver path to a Sync Server configuration file. For connecting to Microsoft SQL Server and other JDBC-compliant databases, you also must update a driver list file.
After you configure the Sync Server, you can create subscriptions that use the JDBC driver. On the Create JDBC Subscription or Create Upload Subscription notebook, you must specify the correct database type and in some cases, the full name of the driver.
Table 2 and Table 3 list the necessary steps for JDBC
and upload subscriptions:
Table 2. Steps for setting up the Sync Server to use JDBC driver for JDBC subscriptions
| DB2 UDB | Informix, Sybase, or Oracle | Microsoft SQL Server |
---|---|---|---|
When setting up the Sync Server before using the JDBC driver for the first time: | None | Add a JDBC driver path |
|
When creating the subscription, on the Source tab of the Create JDBC Subscription notebook: | Select IBM DB2 UDB local from the Driver drop-down list | Select the database type from the Driver drop-down list | Select Other from the Driver drop-down list and enter the driver's full name in the field to the right |
Table 3. Steps for setting up the Sync Server to use JDBC driver for upload subscriptions
| DB2 UDB | Informix, Sybase, or Oracle | Microsoft SQL Server | All other JDBC-compliant database |
---|---|---|---|---|
When setting up the Sync Server before using the JDBC driver for the first time: | None | Add a JDBC driver path | Add a JDBC driver path | Add a JDBC driver path |
When creating the subscription, on the Source tab of the Create Upload Subscription notebook: | Select a DB2 UDB driver from the Driver drop-down list | Select the database type from the Driver drop-down list | Select Other from the Driver drop-down list and enter the driver's full name in the field to the right | Select Other from the Driver drop-down list and enter the driver's full name in the field to the right |
For non-DB2 source databases, you must add the path of the JDBC client driver to a Sync Server configuration file (see the tables on page Table 3). The JDBC client driver is provided by the data source vendor.
To add the JDBC driver path:
SET JDBC_DRV_CP=C:\Oracle\Ora81\jdbc\lib\classes111.zip
You can specify multiple JDBC client drivers. For example:
SET JDBC_DRV_CP=C:\Oracle\Ora81\jdbc\lib\classes111.zip;E:\Informix\JDBC\lib\ifxjdbc-g.jar
# This file specifies which JDBC drivers are used for which databases. # # Format: # {JDBC driver full-name}={database identifier} # # The following database identifiers are supported: # DB2 -------------- for DB2 databases # Ifx -------------- for Informix databases # Oracle ----------- for Oracle databases # SQLServer -------- for Microsoft SQL Server databases # Syb -------------- for Sybase databases # Here is a list of DB2 JDBC drivers: COM.ibm.db2.jdbc.app.DB2Driver=DB2 COM.ibm.db2.jdbc.net.DB2Driver=DB2 com.ibm.as400.access.AS400JDBCDriver=DB2 # Here is a list of Informix JDBC drivers: com.informix.jdbc.IfxDriver=Ifx # Here is a list of Oracle JDBC drivers: oracle.jdbc.driver.OracleDriver=Oracle # Here is a list of SQL Server JDBC drivers: com.jnetdirect.jsql.JSQLDriver=SQLServer # Here is a list of Sybase JDBC drivers: com.sybase.jdbc.SybDriver=Syb
JDBC_driver_full_name=SQLServer
For example:
com.myfastdriver.jdbc.SQLDriver=SQLServer
When you create a JDBC or upload subscription, you must specify the correct driver on the Source tab of the Creating JDBC Subscription or Create Upload Subscription notebook.
In most cases, you only need to select the correct source database type from the Driver drop-down list. The field to the right will be automatically updated with the full name of the JDBC driver.
For DB2 UDB, select DB2 UDB local if the DB2 database is running on the same machine as the Sync Server. Select DB2 UDB remote if the DB2 database is running remotely. For the latter case, make sure the remote DB2 database is configured correctly to allow proper JDBC connection.
If the database is Microsoft SQL Server (for both JDBC and upload subscriptions) or any other JDBC-compliant database (for upload subscriptions), you must: