tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <GTho...@Bacons.com>
Subject Problems with TomCat 5.0 and SQL tag lib
Date Fri, 28 May 2004 14:07:51 GMT
I'm having a lot of problems connecting to a database using the SQL
tag-lib. I'm using Tomcat 5.0 on Windows. Here is the web.xml source:

 

<?xml version="1.0" encoding="ISO-8859-1"?>

 

<!DOCTYPE web-app

    PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"

    "http://java.sun.com/dtd/web-app_2_3.dtd">

 

<web-app version="2.4">

 

  <display-name>Welcome to Tomcat</display-name>

 

  <description>

     Welcome to Tomcat

  </description>

 

  <taglib>

      <taglib-uri>http://java.sun.com/jstl/core</taglib-uri>

      <taglib-location>/WEB-INF/c.tld</taglib-location>

  </taglib>

 

  <taglib>

      <taglib-uri>http://java.sun.com/jstl/sql</taglib-uri>

      <taglib-location>/WEB-INF/sql.tld</taglib-location>

  </taglib>

 

 

</web-app>

 

Here is my jsp source:

 

<%@ taglib prefix="sql" uri="http://java.sun.com/jstl/sql" %>

<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>

 

 

<sql:setDataSource var="datasource"  

            driver="com.microsoft.jdbc.sqlserver.SQLServerDriver" 

 
url="jdbc:microsoft:sqlserver://server1:1433;DatabaseName=crmimic"

            user="sa"

            password=""

 />

 

 

<sql:query var="results" dataSource="${datasource}">

       select URL,org from wcCheckurls

                        where status='UNRESOLVED'

</sql:query>

 

 

<table>

<c:forEach var="row" items="${results.rows}"  

      varStatus="counter"  >

      <tr>

         <td>${counter.count}</td>

         <td>${row.url}</td>

         <td>${row.org}</td>

      </tr>

</c:forEach>

</table>

 

I have put the jstl and standard jar files in my web-inf\lib directory.
I have put the slq.tld and c.tld files in my web-inf directory. When I
run the jsp page I get "no suitable driver" found. I'm running
j2sdk1.4.0_01. 

 

I wasn't having any problems like this with Tomcat 4. Any help I could
get would be great.

 

Thanks

 

George

 


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