Forum Discussion

Philippe_Lebacq's avatar
Philippe_Lebacq
Contributor
14 years ago

JDBC - DB2 no suitable driver error

Hi
I copied drivers from db2Connect in the soapui bin/ext folder but still get this error.
Any help is welcome.
Kinds, Philippe.

COM.ibm.db2.jdbc.app.DB2Driver
jdbc:db2://url:port/system:subsystem:database:user=user;password=password;

Fri Feb 04 10:54:17 CET 2011:ERROR:java.sql.SQLException: No suitable driver
java.sql.SQLException: No suitable driver
at java.sql.DriverManager.getDriver(Unknown Source)
at com.eviware.soapui.support.jdbc.JdbcUtils.initConnection(JdbcUtils.java:50)
at com.eviware.soapui.impl.wsdl.panels.teststeps.JdbcRequestTestStepDesktopPanel$TestConnectionAction.actionPerformed(JdbcRequestTestStepDesktopPanel.java:725)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.Component.processMouseEvent(Unknown Source)
at javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Fri Feb 04 10:54:17 CET 2011:ERROR:com.eviware.soapui.support.SoapUIException: Failed to init connection for drvr [COM.ibm.db2.jdbc.app.DB2Driver], connectionString [jdbc:db2://tmedb2dsd:3200/TMMEDB2D:CWSD:user=plb0453;password=lp29912;]
com.eviware.soapui.support.SoapUIException: Failed to init connection for drvr [COM.ibm.db2.jdbc.app.DB2Driver], connectionString [jdbc:db2://tmedb2dsd:3200/TMMEDB2D:CWSD:user=plb0453;password=lp29912;]
at com.eviware.soapui.support.jdbc.JdbcUtils.initConnection(JdbcUtils.java:62)
at com.eviware.soapui.impl.wsdl.panels.teststeps.JdbcRequestTestStepDesktopPanel$TestConnectionAction.actionPerformed(JdbcRequestTestStepDesktopPanel.java:725)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.Component.processMouseEvent(Unknown Source)
at javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
  • Works OK when using this: com.ibm.db2.jcc.DB2Driver
    instead of COM.ibm.db2.jdbc.app.DB2Driver

    Might be usefull for others ...

    Philippe.
  • Hi, salut Phillipe (français!)
    Try this if you are suing Soapui >3.5.1
    com.eviware.soapui.support.GroovyUtils.registerJdbcDriver( "net.sourceforge.jtds.jdbc.Driver" )
    replace the "" with yours.

    Add this line before using the driver.
  • Thanks for hint.
    I'm on latest version.
    Using the JCC driver is OK for me, so that was solving my problem.
    Kinds Philippe.