Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tomcat 5: cannot create database connection pool

Status
Not open for further replies.

correro

Programmer
Nov 20, 2003
54
CN
I'm new to Tomcat, and need your help desperately. I followed the steps in Tomcat 5 JNDI Datasource HOW-TO to create database connection pool, but I always get

org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null', cause:
java.sql.SQLException: No suitable driver


When I create a conventional Connection using DriverManager, it works, and there's no problem with database queries.

My environments are Windows 2000; J2SE 1.4.2; Tomcat 5.0.16; MySQL 4.0.16
DB driver is com.mysql.jdbc.Driver

My extensive search online didn't get me anything. Can someone PLEASE tell me what is wrong, or give me a working example? Thanks!
 
My problem seemed to be resolved all of a sudden. You can refer to the following thread if you run into similiar issue:

thread137-431734
 
Similar issue ("No suitable driver") using Tomcat 5.0.19, jdk1.4.1_02, RedHat.

In the thread I noticed several references to $CATALINA_HOME/Catalina/localhost/yourapp.xml, but my installation has no Catalina or Catalina/localhost. Am I correct ins assuming this is the same as $CATALINA_HOME/webapps/MyAppName/WEB-INF/web.xml in my version?

Can someone post a known working server.xml and matching web.xml (suitable sanitized), as I believe I've tried all that were recommended above to no avail. thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top