• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

problem with connecting to oracle through jdbc

 
sapana jain
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I wish to connect to oracle backend through jdbc program but i am getting following problem..........


java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver

I am writting the code in netbeans 5.5 and I have followed the necessary steps to have oracle but then also i am getting the problem.......

please help
 
Shailesh Chandra
Ranch Hand
Posts: 1082
Java Oracle Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It seems like you do not have classes12.jar or ojdbc14.jar in your runtime path.


Shailesh
 
sapana jain
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No that is not the case I have added the classes12.jar but thenalso its not working....
 
Shailesh Chandra
Ranch Hand
Posts: 1082
Java Oracle Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
  • How are you running your program, is it through netbeans only, then netbean by default includes everything in compile-time classpath.
  • try importing oracle.jdbc.driver.OracleDriver in your program to check, if you actually have access the the OracleDriver Class



  • Shailesh
     
    Paul Sturrock
    Bartender
    Posts: 10336
    Eclipse IDE Hibernate Java
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Originally posted by sapana jain:
    No that is not the case I have added the classes12.jar but thenalso its not working....


    A ClassNotFoundException only means one thing. How do you run your application?

    Also classes12.jar is specifically when your application runs JDK 1.3 or below. Are you using a very old version of the JDK? If not, I'd get the latest Oracle driver.
     
    • Post Reply
    • Bookmark Topic Watch Topic
    • New Topic