Oracle jdbc driver
I am getting the following error:
ClassNotFoundException: oracle.jdbc.driver.OracleDriver
This is my snipit of code:
Class.forName("oracle.jdbc.driver.OracleDriver");
conn = DriverManager.getConnection(
"jdbc:oracle:thin:@pub:1521:pub",
"name",
"password");
Where do I get this driver? Once I have it, where do I put it? In the same directory as the rest of the jsp pages?
[427 byte] By [
abacaxia] at [2007-11-26 20:57:31]

# 1
if you oracle db installed on you machine you can get the oracle jdbc driver on the jdbc/lib directory, drivers found can be ojdbc14.jar or classes12.jar. Once you have it, put it on the WEB-INF/lib directory of your application. restart application so the changes may take effect
# 2
f you oracle db installed on you machine you can get the oracle jdbc driver on the jdbc/lib directory, drivers found can be ojdbc14.jar or classes12.jar. Once you have it, put it on the WEB-INF/lib directory of your application. restart application so the changes may take effect
If you put it in the common/lib Tomcat container, do you also have to set your classpath or just shutdown and restart?
# 4
I added the ojdbc14.jar and ora9i_2_0_1.jar files to my WEB-INF\lib directory and restarted the application. I now get this error:
C:\Program Files\New Atlanta\ServletExec ISAPI\ServletExec Data\default\GRT\pagecompile\_grt_fire_edit_xjsp.java:18: package oracle does not exist
import oracle.*;
^
1 error
*****
Is it the way I am importing?...
<%@ page import="java.sql.*" %>
<%@ page import="oracle.*" %>
Are the 2 mentioned packages sufficient for what I am trying to do?
See my original post if necessary.
Thank you!!!
# 5
Latest results:
I took away the: <%@page import="oracle.*"%> line.
I am now getting this in my browser:
SQLException: Io exception: The Network Adapter could not establish the connection
By the way...this is a fully functional web server. we have another Java application connecting to the same DB just fine.