I try to configure a JDBC DataSource for my Adaptive Server Anywhere 9 database. Unfortunately without any success so far!
I use Tomcat 5.5.18.

The error is well known and looks as follows:

org.apache.jasper.JasperException: Unable to get connection, DataSource invalid: "org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null'" org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:510) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:375) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
   javax.servlet.http.HttpServlet.service(HttpServlet.java:802)


I use the JDBCODBC driver to connect. Here is the configuration:

server.xml

   <Resource
     name="jdbc/MyService"
     type="javax.sql.DataSource"
     password="sql"
     driverClassName="ianywhere.ml.jdbcodbc.IDriver"
     maxIdle="2"
     maxWait="5000"
     validationQuery="select * from CodeTable"
     username="dba"
     url="jdbc:odbc:dsn=MyService"
     maxActive="50"
     removeAbandoned="true"
     removeAbandonedTimeout="60"
     logAbandoned="true"/>

Web.xml

 <resource-ref>
     <description>Database connection</description>
     <res-ref-name>jdbc/MyService</res-ref-name>
     <res-type>javax.sql.DataSource</res-type>
     <res-auth>Container</res-auth>
 </resource-ref>

Note: I currently do NOT deplay using a WAR file since I use Eclipse as develpment environment to debug etc. So I do NOT have an application specific context.xml file at the moment.

Could anybody please explain what needs to be put into the name property? It seems that jdbc/ is mandatory but what needs to follow the slash is not clear to me! Is it the ODBC datasource name, the database name or any choosen name??

Many thanks for your help.

Tom

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to