tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Schwartz, David (CHR)" <David.Schwar...@pfizer.com>
Subject RE: JSTL problem (was Oracle Type 4 Driver)
Date Thu, 05 Jun 2003 15:51:21 GMT
Jason,
I finally cleaned it up & got it working! Thanks for your help.
I there a way to add that datasource info to an xml file & just use the
dbtags query string within the jsp file? (simialr to the way you describe
using jndi)?

Now on to the jndi stuff...

-----Original Message-----
From: Jason Bainbridge [mailto:jason@jblinux.org]
Sent: Wednesday, June 04, 2003 4:11 PM
To: Tomcat Users List
Subject: Re: JSTL problem (was Oracle Type 4 Driver)


On Thu, 5 Jun 2003 03:57, Schwartz, David (CHR) wrote:
>  <sql:url>jdbc:oracle:thin:xxxxx:1521:yyyy</sql:url>

I don't think it likes the URL you are giving it, is xxxxx the servername or

IP and yyyy the instance name? NB. the thin driver access the server
directly 
so totally ignore your tnsnames.ora, well except for referring to it to get 
the server name and instance name of course.

Also try passing it the username and password with:

<sql:userId>root</sql:userId>
<sql:password>notVerySecure</sql:password>

Another more standard way to use datasources is to use JNDI and define them
in 
your server.xml as per this howto: 
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource-examples-how
to.html

Then you can reduce your connection tag within your JSP pages to something 
like:

<sql:connection id="conn1" dataSource="jdbc/ds1">

Regards,
-- 
Jason Bainbridge
http://jblinux.org

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message