"java.sql.SQLException: No suitable driver"

Hi,

Can anyone help me? I have some JSP pages that load data ORACLE database.

I'm using jboss-4.0.3SP1 .

The jsp code that breaks :

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

<sql:setDataSource var="qspp" driver="oracle.jdbc.driver.OracleDriver" url="jdbc:oracle:thin:@qa-db1.lon.quative.tv:1521:qadb3" user="lwilliams" password="lwilliams"/>

<sql:query var="orderAsset" dataSource="${qspp}">

SELECT * FROM COD_ASSET

</sql:query>

When I try to load the data I get the following error message:

type Exception report

message

15:33:11,765 ERROR [[jsp]] Servlet.service() for servlet jsp threw exception

javax.servlet.jsp.JspException: Unable to get connection, DataSource invalid: "java.sql.SQLException: No suitable driver"

at org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.getConnection(Unknown Source)

at org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.doStartTag(Unknown Source)

at org.apache.jsp.index_jsp._jspx_meth_sql_query_0(org.apache.jsp.index_jsp:196)

at org.apache.jsp.index_jsp._jspService(org.apache.jsp.index_jsp:89)

at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)

at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)

at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)

at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)

at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)

at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)

at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:159)

at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)

at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)

at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)

at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)

at java.lang.Thread.run(Thread.java:595)

thanks

Sacintha

[3469 byte] By [sacinthaa] at [2007-11-27 9:33:08]
# 1
Do you have the oracle.jdbc.driver.OracleDriver class in the correct position in the classpath for your server?
tolmanka at 2007-7-12 22:53:36 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
Yes .It is in web-inf/lib directory.The jar file that i use is ojdbc14.jar.
sacinthaa at 2007-7-12 22:53:36 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

If you're sure that you *need* the "oracle.jdbc.driver.OracleDriver", then this error generally means that the URL specified is in invalid format (thus, not in the format what the driver is expecting and therefore the driver assumes that you're using the wrong driver). Refer to the documentation how to construct a valid URL.

BalusCa at 2007-7-12 22:53:36 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...