Caused by: java.lang.ClassNotFoundException: oracle.jdbc.OracleDriver

前端 未结 2 1632
心在旅途
心在旅途 2020-12-19 12:30

I created a web application with ojdbc14.jar in lib folder.

However, when I start my tomcat I get an error:

Caused by: java.lang.ClassNotFoundExcepti         


        
相关标签:
2条回答
  • 2020-12-19 12:59

    Are you sure it exists inside webapps/yourapp/WEB-INF/lib folder? It is bound to throw that exception if it can't be seen in that specific directory.

    How do you deploy out of eclipse? Do you export a WAR file and deploy? Verify that your WAR file contains ojdbc14.jar in the specified location.

    0 讨论(0)
  • 2020-12-19 13:09

    Please make sure that the jar goes to the tomcat or tamcat gets the reference to the jar. you can do it following ways. 1) as mentioned by Adarsh, put the jar file in WEB-INF/lib folder. 2) in the run-configuration of your tomcat, click on ClassPath and then click on User Entity and then click on add jar where u can select the jar and add it.

    0 讨论(0)
提交回复
热议问题