aspose file tools*
The moose likes Tomcat and the fly likes Tomcat6: no mysql DB connection Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Tomcat6: no mysql DB connection" Watch "Tomcat6: no mysql DB connection" New topic
Author

Tomcat6: no mysql DB connection

Michael Oberleitner
Greenhorn

Joined: Jul 13, 2011
Posts: 16
Hello

I'm using Tomcat 6 and I need to have mysql-DB access in my application but I'm getting this error message:



This is a part which i changed to establish db access in the server.xml:


The password is correctly set.

This is the META-INF/context.xml file:


and this is the web.xml file:


and this is the code of the StartServlet:


I put the mysql-connector-java-5.1.13-bin.jar in the WEB-INF/lib folder of the application and in the apache-tomcat-6.0.26\lib folder, but it seems that tomcat isn't able to find this file.
Last time I used tomcat is three years ago and I never used tomcat 6, so I hope someone could help me here.

Best regards,
Michael
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16145
    
  21


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


I really hate that message. It means that there's something wrong with your JDBC resource definition and it's not going to tell you what.


Customer surveys are for companies who didn't pay proper attention to begin with.
Michael Oberleitner
Greenhorn

Joined: Jul 13, 2011
Posts: 16
I still have the same problem
When additional information is helpful please ask here, because I need db access soon.
Michael Oberleitner
Greenhorn

Joined: Jul 13, 2011
Posts: 16
The solution for this problem is that the server.xml file does not get changed:



It looks like this again.

The context.xml instead looks like this:



After this there is no more-> Cannot create JDBC driver of class '' for connect URL 'null'

regards,
Michael
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Tomcat6: no mysql DB connection