← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #697555]: Connecting to a DB in Sikuli- is there a widely used method for Sikuli 2.0.5?

 

Question #697555 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/697555

    Status: Open => Solved

mpayne confirmed that the question is solved:
Found the solution and it's insultingly simple...

In order for sikuli to use zxJDBC.jar and sqljdbc.jar, they must be put into the following location:
C:\Users\username\AppData\Roaming\Sikulix\Extensions

Sikuli 2.0.5 has the zxJDBC.jar with it, but it is in the Sikulix\Lib
folder. I moved this to extensions and downloaded the latest sqljdbc.jar
driver. With both jar files in the extensions folder, the following code
still connects to the database:

from com.ziclix.python.sql import zxJDBC
connection = zxJDBC.connect(DB URL, Username, Password,'com.microsoft.sqlserver.jdbc.SQLServerDriver')
cursor = connection.cursor()

Hope this helps somebody else.

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for SikuliX.