sql:query error "No suitable driver"
Posted by: Liliya Woland
Date: November 20, 2006 01:11PM

I have a database test code that I made months ago, based on instructions at http://tomcat.apache.org/tomcat-5.0-doc/jndi-datasource-examples-howto.html - it used to work.
When I run it now I get error
org.apache.jasper.JasperException: Unable to get connection, DataSource invalid: "No suitable driver"
I do have all the drivers and classpaths set; have modified server.xml and my web.xml files. The database has the data I'm attempting to query.

Could anyone please tell me what produces the error and maybe how to fix or test for it? Thank you in advance.
This is my test file located in webapps/jsps/ folder

 
<%@ taglib uri="http://java.sun.com/jsp/jstl/sql"; prefix="sql" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core"; prefix="c" %>
 
<sql:query var="rs" dataSource="jdbc/jsps">
select code, description from profilecodes
</sql:query>
<html>
  <head>
    <title>DB Test</title>
  </head>
  <body>
 
  <h2>Results</h2>
  
<c:forEach var="row" items="${rs.rows}">
    code ${row.name}<br/>
    description ${row.description}<br/>
</c:forEach>
 
  </body>
</html>

Options: ReplyQuote


Subject
Written By
Posted
sql:query error "No suitable driver"
November 20, 2006 01:11PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.