• Post Reply Bookmark Topic Watch Topic
  • New Topic

Cannot create JDBC driver of class '' for connect URL 'null'

 
Tom Griffith
Ranch Hand
Posts: 275
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello. if anybody has a minute, this is driving me crazy. I configured a servlet in Tomcat 6 last year to query an Oracle database. It worked. I just revisited it, nothing has changed, and now I get this error...

org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL "null"

Here's what I have...

--------------------------------------- %TOMCAT_HOME%/conf/Catalina/localhost/APP2.xml -----------------------------------------

<?xml version='1.0' encoding='utf-8'?>
<Context displayName="WebApp2" docBase="C:/apache-tomcat/webapps/APP2" path="/EPS2" workDir="work\Catalina\localhost\APP2" debug="0" privileged="true">

<Resource name="jdbc/APP2Train" type="javax.sql.DataSource"/>

<ResourceParams name="jdbc/APP2Train">
<parameter>
<name>url</name>
<value>jdbc:oracle:thin:@142.355.14.103:1521:SE</value>
</parameter>
<parameter>
<name>driverClassName</name>
<value>oracle.jdbc.driver.OracleDriver</value>
</parameter>
<parameter>
<name>username</name>
<value>NAME</value>
</parameter>
<parameter>
<name>PASSWORD</name>
<value>hr</value>
</parameter>

....etc....


-----------------------------------------------


ojdbc14.jar is in %TOMCAT_HOME%/lib




Is there anything I am missing? It was working like 11 months ago and I can't figure out why it can't find the Oracle driver from the APP2.xml. Thank you very much for any help.

Also, i run standalone...

java -cp .;ojdbc14.jar APP2Standalone

with this...

Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();


and it successfully connects, performs SQL, etc. So something seems amiss in the Tomcat configuration. i've tried everything. Thank you.

 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!