I'm experiencing a problem connecting to Oracle 9 from Tomcat 5.5. Have found loads of posts on the net describing the problem, but none of the solutions work for me.
The exception I get is: Cannot create JDBC driver of class '' for connect URL 'null' java.sql.SQLException: No suitable driver at java.sql.DriverManager.getDriver(DriverManager.java:243)
Having run this through the debugger in Tomcat, it's definitely a problem loading the class - when I step into DriverManager.loadInitialDrivers(), I can see that drivers in the following snippet is always null:
I've put ojdbc14.jar under common/lib. I have the following in server.xml:
And in web.xml:
I know the classname is correct, as I have a standalone project which loads the driver and connects to the database fine - the problem only occurs under Tomcat.
I'm really tearing my hair out with this one, so any help greatly appreciated!
Joined: Nov 20, 2003
After a bit more investigation, it's definitely not a driver loading issue, as I can query the db from a Servlet in the same instance by explicitly loading the driver using DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());