• Post Reply Bookmark Topic Watch Topic
  • New Topic

about myodbc

 
ruben chan
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i use mysql server
but i can't connect my db with my javabean
the error message is:
can't find suitable driver;
however, i have already install myodbc on my computer.
and i have already test the data souce.nothing wrong.
i guess the problem is that
mysql sever can't find myodbc driver.
but myodbc driver has found the database.
what to do next?
thank you!
 
Sam Dalton
Author
Ranch Hand
Posts: 170
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you got the driver in your classpath?
S
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Without more information it's hard to say, but this is usually a case of the jar not put in the right place. In many application servers, it doesn't make a difference if you put it on the CLASSPATH, application servers don't use it.
In Tomcat, you need to put the jar in the [ TOMCAT_HOME ]/common/lib directory.
This makes it visible to all web-apps running on the server. If you only want it visible to a specific web-app, put it in the [ TOMCAT_HOME ]/webapps/[ CONTEXT ]/web-inf/lib directory.
Dave
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!