MySQL database connection

Solved!
amungase
Level 2
MySQL database connection

Hi

I am trying to make database connection with MySQL in Dataiku. I have downloaded driver as well but i am using trial/web based version so where exactly I will need to put (which path) my JDBC driver. Is there any option in connection settings to provide driver path? As i am getting error- 

Failed to load database driver: Failed to load JDBC driver (com.mysql.jdbc.Driver), caused by: ClassNotFoundException: com.mysql.jdbc.Driver

1 Solution
ATsao
Dataiker

Hi Amungase,

If you are referring to the hosted trial, then this is indeed not possible as the hosted trial is a bit limited and only provides access to "out-of-the-box" capabilities. If you wish to use the MySQL connector, or any other of our customers that require a driver to be dropped in, you will need to install DSS locally. You can use either the free Community edition or we also provide a 2-week Enterprise trial license if you are interested. More information can be found in our webpage here:

https://www.dataiku.com/product/get-started/

Thanks,

Andrew

View solution in original post

9 Replies
Liev
Dataiker Alumni

Hi @amungase 

You can see a step by step guide here

After you've followed this, you should be able to configure your MySQL connection under Administration.

For more info on MySQL see this section of the docs.

I hope this helps

amungase
Level 2
Author

Thanks for the response. 

i dont have Data Science Studio installed but i am using web trail version instead, so where can i put my driver?

ATsao
Dataiker

Hi Amungase,

If you are referring to the hosted trial, then this is indeed not possible as the hosted trial is a bit limited and only provides access to "out-of-the-box" capabilities. If you wish to use the MySQL connector, or any other of our customers that require a driver to be dropped in, you will need to install DSS locally. You can use either the free Community edition or we also provide a 2-week Enterprise trial license if you are interested. More information can be found in our webpage here:

https://www.dataiku.com/product/get-started/

Thanks,

Andrew

amungase
Level 2
Author

Thanks, was able to make connection with free edition.

Sarissa
Level 2

I am having this issue. I just upgraded to DSS 8.0. I have previously installed 7.x on another machine successfully.

I am using ODBC version 8.0.21, rather than version 8.0.19 that worked for version 7.x. Is there a configuration issue using 8.0.21?

0 Kudos
ATsao
Dataiker

Hi Sarissa,

DSS only supports using JDBC, not ODBC. For more information about setting up a MySQL connection in DSS, please refer to our connector documentation here: 

https://doc.dataiku.com/dss/latest/connecting/sql/mysql.html

Thanks,

Andrew

0 Kudos
Sarissa
Level 2

So, my issue was a Java problem. Once I download the MySQL-Connector-Java-8.0.21, my Java installation could not find it. Hence the "Failed to load database driver" error. I had to unzip the files from Oracle and drop them into my Java library manually. Here are the steps:

  • Copy the JDBC .jar file you downloaded to either the system-wide Java Extensions folder (/Library/Java/Extensions) or your user Java Extensions folder (/Users/username/Library/Java/Extensions).
  • Add the directory containing the JDBC .jar file to the CLASSPATH environment variable (see Modifying the Java CLASSPATH).
  • Specify the directory containing the JDBC .jar using the -cp argument in the Java command line you use to start your Java command line.

I didn't need the last two steps...it worked just dragging the files into the right place.

Cost me a couple of days. Here's to you not having to fight that battle!

Sarissa
Level 2

FYI, this was the fix for Mac OS Catalina.

Kjeanclaude
Level 1

Thank you very much, the first step worked for me too (after a couple of days too). ๐Ÿ˜€

Copy the driverโ€™s JAR file (and its dependencies, if any) to the DATA_DIR/lib/jdbc folder

It is now in the documentation : https://doc.dataiku.com/dss/latest/installation/custom/jdbc.html

0 Kudos