tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ilasno <>
Subject problems connecting to networked odbc data source
Date Tue, 08 Jun 2004 01:54:41 GMT

here's my setup.  i have a development linux server running debian, 
tomcat 5.0.16, and java 1.3. i have successfully connected to a remote 
mysql database (on port 3306 with a connection string like 
'jdbc:mysql://xx.xx.xx.xx:3306/dbName?autoReconnect=true') with a 
datasource configured in the server.xml file.

the computer i work on is running windows 2000 server and is networked 
with the debian linux box, and what i would like to do is configure a 
datasource within the debian tomcat server.xml that would connect with a 
microsoft access database that is set up as a DSN on the windows 
server.  i started with a datasource configuration like this:

<<Resource name="jdbc/dbName" auth="Container" 
type="javax.sql.DataSource" />
- <#> <ResourceParams name="jdbc/ilDb">
- <#>   <parameter>
- <#>   <parameter>

...other parameters, including maxActive, username, password, etc...
- <#> 

but i was getting a null reference when i tried to create the connection 
object from the datasource object.  so, to try to get something going, i 
then moved to an all-code connection, like so:

String url= "jdbc:odbc://";
conn = DriverManager.getConnection(url);

but it's still throwing an exception on the line that attempts to get a 
connection, this time like so:

java.lang.Exception: DB:getTest() failed: No suitable driver
    at net.ilasno.db.DB.getTest(
    at org.apache.jsp.test_jsp._jspService(
    at org.apache.jasper.runtime.HttpJspBase.service(
    at javax.servlet.http.HttpServlet.service(
    at org.apache.jasper.servlet.JspServletWrapper.service(
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(
    at org.apache.jasper.servlet.JspServlet.service(
    at javax.servlet.http.HttpServlet.service(

it's my understanding that the jdbc/odbc bridge driver is a part of the 
core java classes.  at this point i would settle for either technique, i 
just want to access the data!  any suggestions?

thanks for your time

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message