Home » Developer & Programmer » JDeveloper, Java & XML » Jdbc Connectivity using OCI8
Jdbc Connectivity using OCI8 [message #91526] Thu, 17 October 2002 02:57 Go to next message
Manoj
Messages: 101
Registered: August 2000
Senior Member
When i try to connect to database using the following java program it works fine.

DriverManager.registerDriver (new oracle.jdbc.driver.OracleDriver());
Class.forName("oracle.jdbc.driver.OracleDriver");
con=DriverManager.getConnection("jdbc:oracle:oci8:@demotest","manoj","manoj");
pst = con.createStatement();

When i tried to connect to database using a servlet it gives me following run time error.

java.lang.NoClassDefFoundError: oracle/jdbc/driver/OracleDriver
(this error is only for servlet and not for simple java program)
I have classes12.zip and nls_charset12.zip in my classpath. I also have [[oracle_home]]/jdbc/lib in my path. But still i could not solve the problem
I am using apache webserver

Manoj
Re: Jdbc Connectivity using OCI8 [message #91528 is a reply to message #91526] Sat, 19 October 2002 02:57 Go to previous messageGo to next message
Manoj
Messages: 101
Registered: August 2000
Senior Member
I have solved the problem
Re: Jdbc Connectivity using OCI8-->>how did u solve this problem?? [message #91555 is a reply to message #91526] Thu, 07 November 2002 01:34 Go to previous messageGo to next message
bush
Messages: 3
Registered: May 2001
Junior Member
hey how did u solve this problem i am faciing specifically this prolblem

bush
Re: Jdbc Connectivity using OCI8-->>how did u solve this problem?? [message #91571 is a reply to message #91555] Mon, 18 November 2002 02:22 Go to previous messageGo to next message
Manoj
Messages: 101
Registered: August 2000
Senior Member
hi bush

this problem i solved by setting the classpath to the directory where my servlet was saved
and it worked fine
and also i kept the classpath to classes12.zip as it was in my autoexec.bat file (there were no modifications done to this path)

manoj
Re: Jdbc Connectivity using OCI8 [message #92504 is a reply to message #91526] Wed, 18 August 2004 17:49 Go to previous message
Krithiga
Messages: 2
Registered: August 2004
Junior Member
Hi I am facing the same problem - if some one can help me I will appreciate it.
Previous Topic: how to open a dialouge box using JDeveloper
Next Topic: tree structure retreiving for oracle DB
Goto Forum:
  


Current Time: Fri Apr 19 00:39:32 CDT 2024