#1
  1. Modding: Oracle MsSQL Firebird
    Devshed Supreme Being (6500+ posts)

    Join Date
    Jun 2001
    Location
    Outside US
    Posts
    8,527
    Rep Power
    539

    ClassNotFound ... please help


    Hi, I'm trying to install jdbc driver for Mysql, but I get this error:

    java.lang.ClassNotFoundException: org.gjt.mm.mysql.Driver ....

    my etc/profile is:

    CLASSPATH=$CLASSPATH:/usr/java/jre1.3.1_01/lib/mm.mysql.jar
    export CLASSPATH

    what shall I do??
    Plesa help me!
    Thanks
  2. #2
  3. No Profile Picture
    Not A Jedi Yet
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2001
    Location
    Salt Lake City
    Posts
    8
    Rep Power
    0
    What JSP/servlet container are you using?

    The container usually won't share the same classpath as you.

    If you are using Tomcat, you can just throw a copy of the the .jar into $TOMCAT_HOME/lib and restart Tomcat.
  4. #3
  5. Modding: Oracle MsSQL Firebird
    Devshed Supreme Being (6500+ posts)

    Join Date
    Jun 2001
    Location
    Outside US
    Posts
    8,527
    Rep Power
    539

    Thanks, but ...


    I'm not using a servlet container, I was experimenting with JMeter ( http://jakarta.apache.org ) and thanks to a tutorial about Postgresql ( http://www.fankhausers.com/postgresql/jdbc/welcome.html ) I've discovered that:

    - NO CLASSPATH is the best way, just put the driver in /usr/java/jre/lib/ext

    - MySQL.com documents regarding jdbc simply SUCKS!!!!

    Thanks again for your help.
  6. #4
  7. No Profile Picture
    Not A Jedi Yet
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2001
    Location
    Salt Lake City
    Posts
    8
    Rep Power
    0
    The puzzle is solved when you understand what classpath is explicit and implicit with the environment you are running on.

    For general JDBC, you can't beat java.sun.com for tutorials and javaranch.com for people to pester.

IMN logo majestic logo threadwatch logo seochat tools logo