Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

where to put my jdbc driver to mysql?

 
Bob Moranski
Ranch Hand
Posts: 177
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I have a question. Where do I place mm.mysql.jdbc-1.0 package? Please help.
 
Peter Tran
Bartender
Posts: 783
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If the documentation doesn't specify any specific directory, then place it where it makes sense for you and add the *.jar files to your classpath.
For example, where I work we have a project call Foo. Under Foo, we create a tools directory to place all third-party libraries.

-Peter
[This message has been edited by Peter Tran (edited January 11, 2001).]
 
Bob Moranski
Ranch Hand
Posts: 177
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am bit embarrassed to ask...but what is my classpath? Also, the package has subpackages, so, how do I jar it?
[This message has been edited by Bob Moranski (edited January 11, 2001).]
 
Thomas Paul
mister krabs
Ranch Hand
Posts: 13974
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The classpath is the path that tells java where to find classes. Packages can only be accessed when they are on the classpath. If I remember correctly, the package for mysql is located in a jar file called mysql_comp.jar. Put this file is a directory (c:\java\lib might be a good place) and then update your classpath variable to add c:\java\lib\mysql_comp.jar. Jar and Zip files have to listed explicitly.
 
Syed Waqas Badshah
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am a student working on J2EE enviroment using JSP and MySQL. I am using a Webserver JRun 4 and eventually everything is working but I cannot access my database file because it asking me for JDBC driver. As far as I know I have place JDBC driver in every folder but it still don't pick up my JDBC Driver the Jar file.

My program was running before until I have to format my pc. and when I install everything again it is giving me an error in JDBC Driver. Now please tell me how to set my classpath if that is the case or I have to place JDBC Driver somewhere so it could pick it up. I am using JDK1.4.3 and still it can't find my driver.
Please help
its urgent.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34401
346
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Syed,
Welcome to Javaranch!

You don't need to have the driver in the same directory. Just make sure to put the driver jar file in your system CLASSPATH variable.

Also note that the original thread is from 2001. It's ok to start a new thread for a new question.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic