wood burning stoves
The moose likes JDBC and Relational Databases and the fly likes type 4 driver with oracle 9i Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "type 4 driver with oracle 9i" Watch "type 4 driver with oracle 9i" New topic

type 4 driver with oracle 9i

ajit chaudhary

Joined: May 10, 2010
Posts: 8

For the above code we set classpath for oracle as
set classpath="%classpath%";F:\oracle\ora92\jdbc\lib\classes.zip;.;

after compilation then we run & get the following Exception:

F:\lily>javac Prog6.java

F:\lily>java Prog6
Exception in thread "main" java.lang.ClassNotFoundException: oracle.jdbc.driver.
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:164)
at Prog6.main(Prog6.java:8)

Paul Sturrock

Joined: Apr 14, 2004
Posts: 10336

Any reason you want to use such an old driver? With Oracle I'd always grab the latest version I can.

I can't remember there ever being a classes.zip. classes12.zip and classes 13.zip yes, but classes.zip, no. Mind you its been eight years since I used that version of the driver so I might just be remembering wrong.

The oracle.jdbc.driver package was deprecated even back in 9i's day. Have a read of this for better alternatives (and example programs).

JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Have you checked out Aspose?
subject: type 4 driver with oracle 9i
It's not a secret anymore!