java连接oracle数据库警告,在线等大神。
2012-11-30 14:25:55 com.mchange.v2.c3p0.DriverManagerDataSource ensureDriverLoaded
警告: Could not load driverClass oracle.jdbc.dirver.OracleDriver
java.lang.ClassNotFoundException: oracle.jdbc.dirver.OracleDriver
at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1680)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1526)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:169)
at com.mchange.v2.c3p0.DriverManagerDataSource.ensureDriverLoaded(DriverManagerDataSource.java:100)
at com.mchange.v2.c3p0.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:132)
at com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:182)
at com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:171)
at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager.acquireResource(C3P0PooledConnectionPool.java:137)
at com.mchange.v2.resourcepool.BasicResourcePool.doAcquire(BasicResourcePool.java:1014)
at com.mchange.v2.resourcepool.BasicResourcePool.access$800(BasicResourcePool.java:32)
at com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask.run(BasicResourcePool.java:1810)
at com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run(ThreadPoolAsynchronousRunner.java:547)
tomcat 下面有驱动包。
------最佳解决方案--------------------oracle.jdbc.dirver.OracleDriver
这是个类路径,看看包里面有没有这个类,我记得oracle的驱动包有好几个版本呢?看看是不是加错驱动了
------其他解决方案--------------------你先把包copy到当前项目下执行试试,估计那jar包放在tomcat目录下的错误的位置了。
------其他解决方案--------------------有ojdbc14.jar包了。
------其他解决方案--------------------已解决,结贴。
------其他解决方案--------------------你可以打开ojdbc14.jar包,看看是否有oracle.jdbc.dirver.OracleDriver这个类,如果没有,我推荐你个jar包,很不错的。classes12.jar