baztian / jaydebeapi

JayDeBeApi module allows you to connect from Python code to databases using Java JDBC. It provides a Python DB-API v2.0 to that database.
GNU Lesser General Public License v3.0
365 stars 148 forks source link

Problem in connecting teradata to azure databricks #202

Open Beetleferret opened 2 years ago

Beetleferret commented 2 years ago

import jaydebeapi server=server database= db user=user password=pswd

jclassname="com.teradata.jdbc.TeraDriver"

url='jdbc:teradata://server/'

driver_args=[url,user,password]

jars=['/Users/user/drivers/tdgssconfig.jar','/Users/user/drivers/terajdbc4.jar']

jaydebeapi.connect(jclassname,driver_args,jars)

I am getting error of TypeError: Class com.teradata.jdbc.TeraDriver is not found

Please HELP PLEASE

jpsteege commented 2 years ago

Hi Beetleferret,

Looking to your jar paths, it could be that you are on a Mac. It's an old solution, but you could try to start the JVM explicitly using the entries that are stated in this solution: https://downloads.teradata.com/forum/connectivity/problem-connecting-to-teradata-using-python-jaydebeapi-module

Beetleferret commented 2 years ago

Hi jpsteege,

I am able to connect through jupyter but in databricks still its not resolving.

jpsteege commented 2 years ago

Sorry, missed that context. Hopefully you will find a solution/fix soon!