cancel
Showing results for 
Search instead for 
Did you mean: 

JDBC - Problem - ClassLoader

Former Member
0 Kudos

Hi,

I'm trying to access a SQL Server 7 database using SAP XI 3.0 to insert data. For this, I'm using the jTDS driver for JDBC.

I installed this driver in XI using the driver tool to generate a .sda file and I deplyed this file in XI and I restarted XI Server.

In a java program, the jTDS driver acessed the database normally.

See a part of java code:

Class.forName("net.sourceforge.jtds.jdbc.Driver").newInstance();

Connection conn = DriverManager.getConnection ("jdbc:jtds:sqlserver://10.101.193.15:1433","u_itfc_sap","itfc_sap");

See the XI error:

JDBC adapter receiver channel JDBCAdapterSqlServer not initialized. Unable to proceed due to Loading jdbc driver 'net.sourceforge.jtds.jdbc.Driver' failed: java.lang.ClassNotFoundException: net.sourceforge.jtds.jdbc.Driver ------------------------- Loader Info ------------------------- ClassLoader name: [service:com.sap.aii.adapter.jdbc.svc] Parent loader name: [Frame ClassLoader] References: service:com.sap.aii.af.cpa.svc service:com.sap.aii.af.ms.svc service:com.sap.aii.af.svc service:com.sap.aii.adapter.xi.svc library:com.sap.aii.af.lib library:com.sap.aii.messaging.runtime library:com.sap.xi.util.misc common:service:iiop;service:naming;servic

Exception caught by adapter framework: JDBC Adapter configuration not initialized: Loading jdbc driver 'net.sourceforge.jtds.jdbc.Driver' failed: java.lang.ClassNotFoundException: net.sourceforge.jtds.jdbc.Driver ------------------------- Loader Info ------------------------- ClassLoader name: [service:com.sap.aii.adapter.jdbc.svc] Parent loader name: [Frame ClassLoader] References: service:com.sap.aii.af.cpa.svc service:com.sap.aii.af.ms.svc service:com.sap.aii.af.svc service:com.sap.aii.adapter.xi.svc library:com.sap.aii.af.lib library:com.sap.aii.messaging.runtime library:com.sap.xi.util.misc

Delivery of the message to the application using connection AFW failed, due to: JDBC Adapter configuration not initialized: Loading jdbc driver 'net.sourceforge.jtds.jdbc.Driver' failed: java.lang.ClassNotFoundException: net.sourceforge.jtds.jdbc.Driver ------------------------- Loader Info ------------------------- ClassLoader name: [service:com.sap.aii.adapter.jdbc.svc] Parent loader name: [Frame ClassLoader] References: service:com.sap.aii.af.cpa.svc service:com.sap.aii.af.ms.svc service:com.sap.aii.af.svc service:com.sap.aii.adapter.xi.svc library:com.sap.aii.af.lib library:com.sap.aii.messaging.runtime library:com.sap.xi.util.misc.

The config of adapter is:

Adapter Type: JDBC - Receiver
Transport protocol: JDBC 2.0
Message Protocol: Native SQL String
Adapter Engine: Integration Server

JDBC Driver: net.sourceforge.jtds.jdbc.Driver
Connection: jdbc:jtds:sqlserver://10.101.193.15:1433
User name: ****
Password: ****

Persistence: Database
Database Table name: tableTest

Thanks

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Add your jar for jtds.jdbc.Driver under Imported Archives and test.

Regards,

Uma

Former Member
0 Kudos

Uma,

I added the jar in Inported Archives (into Mapping Objects node, is ready?), but occurs the same error.

I need to do anything in Integration Directory after?

Evandro.

Answers (1)

Answers (1)

Former Member
0 Kudos

Did you try redeploying the JDBC driver on XI server and also ensure that you are using correct jar files. Relevant info on Microsoft web site.

If the problem still persists , check the compatibility of the driver version with the JDK version XI server has.

Regards,

Amol

Former Member
0 Kudos

Amol Joshi,

I did a teste using a java program. This driver access the SQL Server 7. In microsoft's site, don't have drivers to SQL Server 7.

Evandro.