File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JDBC and the fly likes Cannot create JDBC driver of class '' for connect URL 'null', Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Cannot create JDBC driver of class Watch "Cannot create JDBC driver of class New topic

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

mona anshita

Joined: Jun 30, 2006
Posts: 5
hi friends..
i m working on developing a web application and want to implement database pooling.

Server:: Tomcat 5.0
DB:: oracle 10g
For database pooling, I used the element <GlobalNamingResources>

After these settings, the Tomcat Admin shows the Data Source Created with name jdbc/PMS

When I run the application and hit the url where the database connection is obtained, I get the following error::

org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null',
Can somebody help me on this ?

Following is my settings.

<!-- Example Server Configuration File -->
<!-- Note that component elements are nested corresponding to their
parent-child relationships with each other -->

<!-- A "Server" is a singleton element that represents the entire JVM,
which may contain one or more "Service" instances. The Server
listens for a shutdown command on the indicated port.

Note: A "Server" is not itself a "Container", so you may not
define subcomponents such as "Valves" or "Loggers" at this level.

<Server port="8005" shutdown="SHUTDOWN" debug="0">

<!-- Global JNDI resources -->

<!-- Test entry for demonstration purposes -->
<Environment name="simpleValue" type="java.lang.Integer" value="30"/>

<!-- Editable user database that can also be used by
UserDatabaseRealm to authenticate users -->
<Resource name="UserDatabase" auth="Container"
description="User database that can be updated and saved">
<ResourceParams name="UserDatabase">

<ResourceParams name="jdbc/PMS">

<!-- Maximum number of dB connections in pool. Make sure you
configure your mysqld max_connections large enough to handle
all of your db connections. Set to 0 for no limit.

<!-- Maximum number of idle dB connections to retain in pool.
Set to -1 for no limit. See also the DBCP documentation on this
and the minEvictableIdleTimeMillis configuration parameter.

<!-- Maximum time to wait for a dB connection to become available
in ms, in this example 10 seconds. An Exception is thrown if
this timeout is exceeded. Set to -1 to wait indefinitely.

<!-- MySQL dB username and password for dB connections -->


<!-- The JDBC connection url for connecting to your MySQL dB.
The autoReconnect=true argument to the url makes sure that the
mm.mysql JDBC Driver will automatically reconnect if mysqld closed the
connection. mysqld by default closes idle connections after 8 hours.

//*********web.xml settings*******
<description>Database connection resource</description>
please help me to remove this error

Joined: Sep 12, 2003
Posts: 2

Have you checked that the oracle jdbc libraries are in the correct location?


Joined: Sep 12, 2003
Posts: 2
oh and it looks like you are connecting via odbc, not thin or oci, do you mean to do this?

wood burning stoves
subject: Cannot create JDBC driver of class '' for connect URL 'null',
Similar Threads
the SQLNestedException makes my crazy
Tomcat Connection Pooling Help required
Configuring a MySQL DataSource in Tomcat5
problem in getting sybase Datasource in Tomcat 4.1.12
DataSource Invalid