Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm developing an application using Java and MySQL. I've installed libmysql-java package as a database connector, but the installed connector implements version 3.0 of the JDBC specification.

Does anybody know which packages or connectors are needed to install for using JDBC 4.0 in Ubuntu 12.04 using MySQL.

I'm using

  • Java (java version "1.7.0_04")
  • MySQL (mysql Ver 14.14 Distrib 5.5.22)
share|improve this question

2 Answers 2

up vote 3 down vote accepted

According to this page 5.1.x versions of Connector/J supports JDBC 4.0 and the version of Connector/J available in latest Ubuntu repository is libmysql-java 5.1.16-2. So the driver you are using probably supports JDBC 4.0.

share|improve this answer
    
Thanks, I was confused because package description which does not suggest anything about jdbc 4.0 –  bitsbuffer Jun 1 '12 at 12:42
    
@Sky don't immediately go by package description. –  Thomas W. Jun 1 '12 at 13:18
    
Glad if it has helped, please accept it as the correct answer unless you need other information. –  Samik Jun 1 '12 at 19:39

One can download the latest connector from the MySQL website

Extract the tar and use mysql-connector-java-5.1.20-bin.jar as mysql-connector

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.