Reputation: 3037
I am trying to create a sample Spring application with JPA (MySQL DB) and Tomcat 7.0.28 under Mac OSX platform. I placed mysql-connector-java-5.1.22 jar under WEB-INF/lib folder of the application. But when I start the app, I get error mentioned in the Title. I tried to put the same jar under Tomcat lib folder as well but getting the same error.
Same application when I deployed in Glassfish server with driver jar under domain/lib/ext folder, application works fine.
Note: Glassfish was also throwing the same error without putting the driver jar under domain/lib/ext folder.
Upvotes: 1
Views: 2227
Reputation: 2314
Does this How to fix: "No suitable driver found for jdbc:mysql://localhost/dbname" error when using pools? help ? Please check the second answer if you are connecting through program.
Upvotes: 1