tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Turner <rturner...@yahoo.co.uk>
Subject Database Driver
Date Fri, 07 Sep 2001 05:29:53 GMT
I downloaded JSQLConnect, JDBC MSSQL type 4 driver,
but I am failing to get it to work. I am using Windows
XP (RC1), MSSQL7, IIS5 and Tomcat 3.3
 
I have placed the jsqlconnect.jar in the tomcat lib
folder and have also placed that location in the
CLASSPATH environmental variable.
 
The code I am using to test it is:
 
<%@ page language="java" import="java.sql.*" %>
<!--
File: index.jsp
Author: Robert T Turner
Date: September 2001
-->
<%

Class.forName("com.jnetdirect.jsql.JSQLDriver");

Connection
myConn=DriverManager.getConnection("jdbc:JSQLConnect://localhost/database=Directory&user=dailer&password=phone");

Statement stmt=myConn.createStatement();
String query="SELECT * FROM Misc_Numbers ORDER BY
description";

ResultSet rs=stmt.executeQuery(query);

The error message I am getting is

Error: 500
Location: /jsp/index.jsp
Internal Servlet Error:
 
javax.servlet.ServletException: Unable to load class
com.jnetdirect.jsql.JSQLDriver
 at
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:459)
 at
_0002findex_0002ejspindex_jsp_14._jspService(_0002findex_0002ejspindex_jsp_14.java:118)
 at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
 at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at
org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.java:130)
 at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:282)
 at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429)
 at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500)
 at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)
 at
org.apache.tomcat.core.Handler.service(Handler.java:287)
 at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
 at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:812)
 at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
 at
org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection(Ajp12ConnectionHandler.java:166)
 at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
 at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
 at java.lang.Thread.run(Thread.java:484)
 
Root cause: 
java.lang.ClassNotFoundException: Unable to load class
com.jnetdirect.jsql.JSQLDriver
 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(ClassLoader.java:313)
 at java.lang.Class.forName0(Native Method)
 at java.lang.Class.forName(Class.java:120)
 at
_0002findex_0002ejspindex_jsp_14._jspService(_0002findex_0002ejspindex_jsp_14.java:62)
 at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
 at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at
org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.java:130)
 at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:282)
 at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429)
 at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500)
 at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)
 at
org.apache.tomcat.core.Handler.service(Handler.java:287)
 at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
 at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:812)
 at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
 at
org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection(Ajp12ConnectionHandler.java:166)
 at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
 at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
 at java.lang.Thread.run(Thread.java:484)
 
Is there something I need to set up in any of the
properties files or xml files?

Other JSP files work without problems.
 
I think I am starting to round in circles, can anyone
help me?
 
Thanks
Robert T Turner

 

 



____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie

Mime
View raw message