Hi all,
I am a beginner in
JSP. I am Using
Tomcat 3.2 as server and Cloudescape364 as db on Win98 OS. I am unable to connect to the database through JSP. If I execute Cloudescape alone from the DOS prompt the database starts up fine. But when I try to execute my JSP (to connect to the database) it fails to connect and throws the following error:
Internal
Servlet Error:
javax.servlet.ServletException: Unable to load class COM.cloudscape.core.JDBCDriver
at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:459)
at _0002fupdatephonebook_0002ejspupdatephonebook_jsp_10._jspService(_0002fupdatephonebook_0002ejspupdatephonebook_jsp_10.java:123)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at ...........
Root cause:
java.lang.ClassNotFoundException: Unable to load class COM.cloudscape.core.JDBCDriver
at org.apache.jasper.servlet.JasperLoader.findClass(JasperLoader.java:223)
at org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:147)
at java.lang.ClassLoader.loadClass(ClassLoader.java:253)
at java.lang.ClassLoader.loadClassInternal.......
Here is the portion of the code that I am using:
Class.forName("COM.cloudscape.core.JDBCDriver");
Connection con = DriverManager.getConnection("jdbc:cloudscape:C:/MyJSP/phonebook");
Statement st = con.createStatement();
Please let me know if you need more information to under the problem.
NOTE: Also I tried to connect to SQLAnywhere 5.5 using the following code:
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection con = DriverManager.getConnection("jdbc
dbc:contact","dba","sql");
Statement st = ct.createStatement();
When I exeute the JSP (with the above code) it throws me a GPF and the server crashes.
Please help me.
Raj.