Hi,
Im writing a
servlet which should connect to an oracle database
and retrieve some data. When i do this from a
java application it
runs fine but it doesnt work when i use the same code in a servlet.
Is it that Type 2 drivers dont work with servlets ? What are my
alternatives ?
Am pasting relavent code:
String sConn = "jdbc
racle
ci8:admin/admin@FRAME";
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
String str = "oracle.jdbc.driver.OracleDriver";
Class.forName(str);
}
catch(ClassNotFoundException c) {
out.println("Class.forName failed");
}
.........................
.........................
Please advise.
Thanx,
Chetan