[jboss-user] [JCA/JBoss] - Re: No suitable driver found for java:PostgresDS

jaikiran do-not-reply at jboss.com
Tue Nov 27 03:07:41 EST 2007


"chewbacca" wrote : 
  |   When I use this code, IT DOESN'T WORK:
  | 
  |      <sql:setDataSource  var="example"  dataSource="java:/PostgresDS"/>
  | 
  |        <sql:query var="qryPosts" dataSource="${example}">
  |                   SELECT postname, comments FROM public.posts
  |           </sql:query>
  | 
  | I believe the problem is the way I have configured the data source on JBoss. I probably have done something wrong, but I followinf the JBoss Getting Started guide besides other resources.
  | 
  | 

Andre,

I dont have any experience with JSTL tags, but going by what a similar post (http://forum.java.sun.com/thread.jspa?threadID=790011&messageID=9405859) says, it looks like the way the tag is interpreting the datasource JNDI name. By default, the JNDI name is bound to the java: namespace. If you want it to be available in the java:/comp/env namespace of your application(so that it can be used in the JSTL tag), then you will have to explicitly make a mention of it(using the resource-ref element) in the web.xml and jboss-web.xml.




View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4107952#4107952

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4107952



More information about the jboss-user mailing list