- This topic has 3 replies, 2 voices, and was last updated 12 years ago by
support-swapna.
-
AuthorPosts
-
RickSudsMemberHello All,
Getting a ClassNotFoundException for MySQL jdbc driver, I added the driver to the build path project but when running the project the IDE insists its not there.
I think I’m adding it correctly althought it seems to want a MyEclipse compatible version of the driver, I added the one I have by copying it to my project, It still insists its not there and throws classnotfound…Any ideas on what Im doing wrong.
Thanks
RickSudsJune 5, 2013 at 12:45 am #339696
support-swapnaModeratorRickStuds,
You need to copy your driver to the /lib dir of the application server you are deploying to (common/lib for Tomcat). After that the app server will be able to find the driver and fire it up in your app for you.
Let us know how it works for you.
June 5, 2013 at 6:44 am #339707
RickSudsMemberHello Swapna
Thanks for getting back to me, I tried to copy the file to common/lib directory. It does not seem to exist in my version of Tomcat. I tried putting it in the /lib instead. Results where the same exception being thrown. Any ideas?
Thanks Again
Still no luck! Just as an experiment, I tried switching over to another server Glassfish in this case, No good still, it gave me a fit when I tried to setup glassfish and now its shooting no Application.wadl exceptions in the REST explorer…This is intensely annoying, and, after 2 days of this non-sense I’m considering going back to netbeans.
June 6, 2013 at 5:37 am #339743
support-swapnaModeratorRickSuds,
Sorry that you are still seeing issues.
You can put the jar in Tomcat/lib or YourApp/WEB-INF/lib. Make sure you add the jar at once place and there are no two definitions for one class.Can you make sure you can connect to the MySQL database from the MyEclipse Database Explorer Perspective with the version of MySQL driver jar you are working ?
Please share the version details of Tomcat server, MySQL and the MySQL driver jar you are working with.
-
AuthorPosts