下载mysql的jdbc驱动啊~ www.mysql.com就有
解决方案 »
- struts2 上传 文件 到 远程 服务器
- 嵌入式linux系统开发经验者面试J2EE开发如何
- 用Hibernate的时候,pojo 中能不能定义Map类型的成员变量,为什么?
- MyEcplise 5.5 SSH整合问题
- 完了,没分了,请教简单的问题,如果把这个查询语句变成模糊查询呢??
- RMI对象传递出错
- 我是菜鸟,想参加编程培训,不知是否有效果?请各位给点意见!
- 有谁看过“Struts在行动”这本书?
- 求人事管理系统设计思路
- 按以下代码使用OkHttpClient ,会造成socket连接未关闭吗?
- 怎么调用临时表的删除出错阿?drop table #t1
- intellj idea,有些地方还是青蛙跳井啊“不懂”望各位帮忙
我现在用的是mysql4.0.12
jar mm.mysql-2.0.4-bin.jar
好象和你一样
我用的很正常
所以还是建议你看看你有没有把jar放到工程属性中
最简单的办法,看你最后的war或者ear里有没有这个jar
如果是应该把JDBC驱动放到TOMCAT_HOME/common/lib目录下
不要放在WEB-INF/lib下
Tomcat文档有如下一段话
DBCP uses the Jakarta-Commons Database Connection Pool. It relies on number of Jakarta-Commons componenets: Jakarta-Commons DBCP 1.0
Jakarta-Commons Collections 2.0
Jakarta-Commons Pool 1.0
These jar files along with your the jar file for your JDBC driver should be installed in $CATALINA_HOME/common/lib.
NOTE:Third Party drivers should be in jarfiles, not zipfiles. Tomcat only adds $CATALINA_HOME/common/lib/*.jar to the classpath.
NOTE: Do not install these jarfiles in your /WEB-INF/lib, or $JAVA_HOME/jre/lib/ext, or anywhere else. You will experience problems if you install them anyplace other than $CATALINA_HOME/common/lib.