my sql connectivity

Discussion in 'Java' started by focode, Apr 29, 2008.

  1. focode

    focode Guest

    i have downloaded "mysql-connector-java-5.1.6.tar" and the related
    connecter for java and set the class path , my programa compiled well
    but it reported error class not found exception then preceded
    by ...................

    "java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
    at java.net.URLClassLoader$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClassInternal(Unknown Source)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Unknown Source)"

    i want to learn the connectivity with mysql , can any one suggest a
    simple tutorial

    thanks
     
    focode, Apr 29, 2008
    #1
    1. Advertising

  2. focode wrote:
    > i have downloaded "mysql-connector-java-5.1.6.tar" and the related
    > connecter for java and set the class path , my programa compiled well
    > but it reported error class not found exception then preceded
    > by ...................
    >
    > "java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
    > at java.net.URLClassLoader$1.run(Unknown Source)
    > at java.security.AccessController.doPrivileged(Native Method)
    > at java.net.URLClassLoader.findClass(Unknown Source)
    > at java.lang.ClassLoader.loadClass(Unknown Source)
    > at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
    > at java.lang.ClassLoader.loadClass(Unknown Source)
    > at java.lang.ClassLoader.loadClassInternal(Unknown Source)
    > at java.lang.Class.forName0(Native Method)
    > at java.lang.Class.forName(Unknown Source)"
    >
    > i want to learn the connectivity with mysql , can any one suggest a
    > simple tutorial
    >
    > thanks


    You don't have the *jar* file in the classpath. Your program will compile
    well without the driver because it's loaded by name.

    Best regards,
    Leonard

    --
    Simplicity is the ultimate sophistication.
    -- Leonardo da Vinci
     
    Leonard Milcin, Apr 29, 2008
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Gareth
    Replies:
    0
    Views:
    433
    Gareth
    Nov 10, 2003
  2. Replies:
    4
    Views:
    568
    OMouse
    Aug 18, 2005
  3. Trivedi Chinkal

    Connectivity of ASP.NET 2.0 with SQL server 2000

    Trivedi Chinkal, Nov 5, 2008, in forum: ASP .Net
    Replies:
    1
    Views:
    404
    Cowboy \(Gregory A. Beamer\)
    Nov 6, 2008
  4. Hammad Rajjoub

    Problem with Remote SQL Server Connectivity

    Hammad Rajjoub, May 12, 2004, in forum: ASP .Net Security
    Replies:
    0
    Views:
    106
    Hammad Rajjoub
    May 12, 2004
  5. Hammad Rajjoub

    Remote SQL Connectivity Problem with ASP.Net Web Application

    Hammad Rajjoub, May 13, 2004, in forum: ASP .Net Security
    Replies:
    3
    Views:
    111
    Ken Schaefer
    May 14, 2004
Loading...

Share This Page