Error trying to Connect a SQL Server in a Workflow

HI,

I’m trying to establish a connection with a SQL Server database, but the Process Studio Wizard returns an error as stated below.

Error connecting to database [DATABASE] :com.automationedge.ps.core.exception.ProcessStudioDatabaseException:
Error occurred while trying to connect to the database

Driver class ‘sun.jdbc.odbc.JdbcOdbcDriver’ could not be found, make sure the ‘MS SQL Server’ driver (jar file) is installed.
sun.jdbc.odbc.JdbcOdbcDriver

com.automationedge.ps.core.exception.ProcessStudioDatabaseException:
Error occurred while trying to connect to the database

Driver class ‘sun.jdbc.odbc.JdbcOdbcDriver’ could not be found, make sure the ‘MS SQL Server’ driver (jar file) is installed.
sun.jdbc.odbc.JdbcOdbcDriver

at com.automationedge.ps.core.database.Database.normalConnect(Database.java:474)
at com.automationedge.ps.core.database.Database.connect(Database.java:372)
at com.automationedge.ps.core.database.Database.connect(Database.java:343)
at com.automationedge.ps.core.database.Database.connect(Database.java:333)
at com.automationedge.ps.core.database.DatabaseFactory.getConnectionTestReport(DatabaseFactory.java:79)
at com.automationedge.ps.core.database.DatabaseMeta.testConnection(DatabaseMeta.java:2798)
at com.automationedge.ps.ui.core.database.dialog.DatabaseDialog.test(DatabaseDialog.java:109)
at com.automationedge.ps.ui.core.database.wizard.CreateDatabaseWizardPage2.test(CreateDatabaseWizardPage2.java:156)
at com.automationedge.ps.ui.core.database.wizard.CreateDatabaseWizardPage2$3.widgetSelected(CreateDatabaseWizardPage2.java:146)
at org.eclipse.swt.widgets.TypedListener.handleEvent(Unknown Source)
at org.eclipse.swt.widgets.EventTable.sendEvent(Unknown Source)
at org.eclipse.swt.widgets.Display.sendEvent(Unknown Source)
at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Unknown Source)
at org.eclipse.swt.widgets.Display.readAndDispatch(Unknown Source)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:820)
at org.eclipse.jface.window.Window.open(Window.java:796)
at com.automationedge.ps.ui.core.database.wizard.CreateDatabaseWizard.createAndRunDatabaseWizard(CreateDatabaseWizard.java:130)
at com.automationedge.ps.ui.studio.ProcessStudio.createDatabaseWizard(ProcessStudio.java:8004)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.pentaho.ui.xul.impl.AbstractXulDomContainer.invoke(AbstractXulDomContainer.java:313)
at org.pentaho.ui.xul.impl.AbstractXulComponent.invoke(AbstractXulComponent.java:157)
at org.pentaho.ui.xul.impl.AbstractXulComponent.invoke(AbstractXulComponent.java:141)
at org.pentaho.ui.xul.jface.tags.JfaceMenuitem.access$100(JfaceMenuitem.java:43)
at org.pentaho.ui.xul.jface.tags.JfaceMenuitem$1.run(JfaceMenuitem.java:106)
at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)
at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:545)
at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:490)
at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:402)
at org.eclipse.swt.widgets.EventTable.sendEvent(Unknown Source)
at org.eclipse.swt.widgets.Display.sendEvent(Unknown Source)
at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Unknown Source)
at org.eclipse.swt.widgets.Display.readAndDispatch(Unknown Source)
at com.automationedge.ps.ui.studio.ProcessStudio.readAndDispatch(ProcessStudio.java:1469)
at com.automationedge.ps.ui.studio.ProcessStudio.waitForDispose(ProcessStudio.java:8339)
at com.automationedge.ps.ui.studio.ProcessStudio.start(ProcessStudio.java:9661)
at com.automationedge.ps.ui.studio.ProcessStudio.main(ProcessStudio.java:738)

Caused by: com.automationedge.ps.core.exception.ProcessStudioDatabaseException:
Driver class ‘sun.jdbc.odbc.JdbcOdbcDriver’ could not be found, make sure the ‘MS SQL Server’ driver (jar file) is installed.
sun.jdbc.odbc.JdbcOdbcDriver

at com.automationedge.ps.core.database.Database.connectUsingClass(Database.java:517)
at com.automationedge.ps.core.database.Database.normalConnect(Database.java:458)
... 40 more

Caused by: java.lang.ClassNotFoundException: sun.jdbc.odbc.JdbcOdbcDriver
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at com.automationedge.ps.core.database.Database.connectUsingClass(Database.java:492)

AE Support gave me the solution, I’ll reply here:
It worked for me.

  1. Download the jtds.jar driver https://sourceforge.net/projects/jtds/files/ or use this link jtds-1.3.1.jar (310.4 KB)
  2. Place it into process-studio/lib directory
  3. Close process-studio and try again.
1 Like