You hit this brick wall within minutes of trying to use report studio for the first time.
I cannot find any documenation which says how to get this jar, or how to include it on the class path which various forums say is the answer to this error.
The only place I can find the driver is here: http://dev.mysql.com/downloads/connector/j/
But sadly, this only allows you to download an MSI installer, not the jar.
Please could someone tell me where to get the jar, and how to edit jasper studios class path to include it.
I have mysql installed and a 1.7 java JDK, but neither install dirs seem to contain the missing mysql jar.
Windows 8 64 bit, My SQL 5.6, studio 5.6.0.final.
Why is this not included? It would save untold pain for users who just want to write reports against mysql - not learn how to administer java.
The post author has a valid point, it's amazing that step-by-step instructions for new users dissolve into obscurity in cases like this. Granted there are multiple environments to take into account, but clear instructions for the 5 or so most common installations would be helpful. If a user needs to Google assistance, the instructions are inherently lacking.
For those working on a Windows installation and a MySQL database, here's what worked (and didn't work) for me:
- You will need a JDBC driver .jar file. Go to http://dev.mysql.com/downloads/connector/j/ , and download the file identified by 'Platform Independent (Architecture Independent), ZIP Archive'.
- Open the mysql-connector-java-x.x.x.zip file; open the folder 'mysql-connector-java-x.x.x'. This should reveal a set of files that include 'mysql-connector-java-x.x.x-bin.jar'.
- Copy this jar file to your server; I created a dedicated folder, C:/jdbc for this purpose.
- Discover the issue shown at http://community.jaspersoft.com/wiki/tibco-jaspersoft-studio-jdbc-connec... . Ignore all the fuss you may read about modifying CLASSPATH.
- In Jaspersoft Studio, click the 3rd icon in the icon bar after 'Build All' (this is the 'New Data Adapter' icon; there is no menu equivalent for this). Set your adapter folder/filename, then click Next.
- Select 'Database JDBC Connection'; click Next.
- Set the following in the 'Database Location' tab:
- JDBC Driver: MySQL (com.mysql.jdbc.Driver)
- JDBC URL: jdbc:mysql://localhost:3306/your-database-name (3306 is a default MySQL port, yours might be different)
- Username: (admin-access account name for database)
- Password: (admin-access account password for database)
- As noted in the above link, select the 'Driver Classpath' tab; click Add.
- Find your saved jar file and add it here.
- Click Test to test the connection; hopefully everything worked and your connection succeeded. Click Finish to save.
Is not included for license contraints on the MySQL side. If you install that MSI it will create a folder with the JAR's you need.
Also the MariaDB driver which is included is compatible with MySQL (https://mariadb.com/kb/en/mariadb/client-libraries/mariadb-java-client/a...) so you can use that one
Lisay_1's answer worked for me - thank you VERY much!!
I ran into a subsequent timezone error that's apparently related to versions of the driver, giving the following error:
The server time zone value 'PDT' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the 'serverTimezone' configuration property) to use a more specific time zone value if you want to utilize time zone support.
Simply follow the solution here:
Hope this helps someone else.