The web.xml wouldn't change much, just put a resource reference to your
datasource

<web-app>
  <description>Oracle Test App</description>
[...] <!-- other stuff regarding the app -->
  <resource-ref>
    <description>Oracle Datasource example</description>
    <!-- use the same name as used in the server.xml file -->
    <res-ref-name>jdbc/myoracle</res-ref-name>     
    <res-type>javax.sql.DataSource</res-type>
    <res-auth>Container</res-auth>
  </resource-ref>
</web-app>

The thing that matters here is the server.xml file, which is where you
define the (application-server-wide-available) datasource.

The jar file should be in $CATALINA_HOME/common/lib/

Good luck,

Tom
 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: jeudi 23 septembre 2004 15:32
To: Tomcat Users List
Subject: RE: Oracle Driver and JDBC-ODBC still refuses to load

I did try what was explained in
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource-examples
-howto.html  I could have missed some step I guess. 
Tom: what would a web.xml file look like if I tried it the J2EE way?


-------------- Original message -------------- 

> Thank you Yoav :-) 
> 
> To set up a datasource on Tomcat (container provided connection
pooling) 
> the following link might help: 
> 
>
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource-examples

> -howto.html 
> 
> Tom Vekemans 
> 
> -----Original Message----- 
> From: Shapira, Yoav [mailto:[EMAIL PROTECTED] 
> Sent: jeudi 23 septembre 2004 15:10 
> To: Tomcat Users List 
> Subject: RE: Oracle Driver and JDBC-ODBC still refuses to load 
> 
> 
> Hi, 
> 
> >My suggestion: package your application the J2EE way. Create a .war 
> file 
> >with in it a WEB-INF directory. Put your web.xml under WEB-INF, your 
> >classes in WEB-INF\classes (including the package structure) and your

> >jars (driver classes) under WEB-INF\lib 
> 
> That, of course, is impossible if you want to use container-provided 
> connection pooling. If one wants to load and configure one's own 
> connection pooling, the above advice is excellent, and it's what I 
> follow myself usually. 
> 
> Yoav 
> 
> 
> 
> This e-mail, including any attachments, is a confidential business 
> communication, and may contain information that is confidential, 
> proprietary and/or privileged. This e-mail is intended only for the 
> individual(s) to whom it is addressed, and may not be saved, copied, 
> printed, disclosed or used by anyone else. If you are not the(an) 
> intended recipient, please immediately delete this e-mail from your 
> computer system and notify the sender. Thank you. 
> 
> 
> --------------------------------------------------------------------- 
> To unsubscribe, e-mail: [EMAIL PROTECTED] 
> For additional commands, e-mail: [EMAIL PROTECTED] 
> 
> 
> 
> --------------------------------------------------------------------- 
> To unsubscribe, e-mail: [EMAIL PROTECTED] 
> For additional commands, e-mail: [EMAIL PROTECTED] 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to