Cannot load JDBC driver class 'com.mysql.jdbc.driver' 10
用maven写springmvc项目报一下错误但是我有添加mysql-connector-javajar包CannotloadJDBCdriverclass'com.my...
用maven写spring mvc项目 报一下错误 但是我有添加mysql-connector-java jar包
Cannot load JDBC driver class 'com.mysql.jdbc.driver'
java.lang.ClassNotFoundException: com.mysql.jdbc.driver
at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50)
at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:244)
at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:230)
at org.mortbay.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:401)
at org.mortbay.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:363)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1130)
at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:880) 展开
Cannot load JDBC driver class 'com.mysql.jdbc.driver'
java.lang.ClassNotFoundException: com.mysql.jdbc.driver
at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50)
at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:244)
at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:230)
at org.mortbay.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:401)
at org.mortbay.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:363)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1130)
at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:880) 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询