Results 1 to 5 of 5
  1. #1
    juhiswt is offline Member
    Join Date
    Mar 2011
    Posts
    30
    Rep Power
    0

    Default JDBC Connectivity in netbeans

    I m trying to connect ms access through net beans ......same code is working properly in cui but not in netbeans. Its giving the warning

    Exception in thread "main" java.lang.ClassNotFoundException: sun.jbbc.odbc.JdbcOdbcDriver
    at java.net.URLClassLoader$1.run(URLClassLoader.java: 202)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.j ava:190)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:3 06)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launche r.java:301)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:2 47)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:169)
    at cs.server.main(server.java:9)
    Java Result: 1

  2. #2
    Tolls is offline Moderator
    Join Date
    Apr 2009
    Posts
    11,450
    Rep Power
    19

    Default

    What JDK are you pointing at?
    That should work, since that class is in rt.jar.

  3. #3
    juhiswt is offline Member
    Join Date
    Mar 2011
    Posts
    30
    Rep Power
    0

    Default

    Its JDK 1.6...

  4. #4
    Tolls is offline Moderator
    Join Date
    Apr 2009
    Posts
    11,450
    Rep Power
    19

    Default

    What machine are you on?
    All of my windows JDks have that in rt.jar.

    Not that I'll get to reply til tomorrow...off home now.

  5. #5
    juhiswt is offline Member
    Join Date
    Mar 2011
    Posts
    30
    Rep Power
    0

    Default

    Thank u .....but the problem has been solved ...that was my mistake only i was missing the try catch block...thank u again

Similar Threads

  1. jdbc connectivity error
    By OMFGITSROHIT in forum JDBC
    Replies: 2
    Last Post: 03-16-2010, 05:10 PM
  2. JDBC with Netbeans/Oracle
    By sehudson in forum Advanced Java
    Replies: 1
    Last Post: 03-11-2010, 09:26 AM
  3. Replies: 7
    Last Post: 12-08-2008, 06:20 PM
  4. Replies: 0
    Last Post: 04-01-2008, 10:17 AM
  5. Netbeans platform - JDBC module
    By sara in forum NetBeans
    Replies: 2
    Last Post: 07-10-2007, 01:21 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •