I haven't been able to get the example to work.  I (was sure) that I followed the 
examples, but I still
haven't been able to get this to work for me.

Initially I was getting the 'can't create driver null' error and now I'm getting 
'object not bound in this
context' errors.  Can you tell me where exactly you put this code?

Thanks,

Tom

Jacob Kjome wrote:

> The oracle driver works just dandy for me.  I renamed classes12.zip to
> classes12.jar and put it in common/lib.  Make absolutely sure that you
> don't include the oracle driver in your WEB-INF/lib.   You will just
> confuse the classloaders.  Put it in common/lib and that is it, end of story.
>
> Then I set up my config like this:
>
> <Resource name="jdbc/myDB" auth="Container"
>            type="javax.sql.DataSource"/>
> <ResourceParams name="jdbc/myDB">
>      <parameter>
>          <name>username</name>
>          <value>scott</value>
>      </parameter>
>      <parameter>
>          <name>password</name>
>          <value>tiger</value>
>      </parameter>
>      <parameter>
>          <name>driverClassName</name>
>          <value>oracle.jdbc.driver.OracleDriver</value>
>      </parameter>
>      <parameter>
>          <name>url</name>
>          <value>jdbc:oracle:thin:@oracleserver:1521:mydatabase</value>
>      </parameter>
>      <parameter>
>          <name>factory</name>
>          <value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
>      </parameter>
>      <parameter>
>          <name>maxActive</name>
>          <value>100</value>
>      </parameter>
>      <parameter>
>          <name>maxIdle</name>
>          <value>30000</value>
>      </parameter>
>      <parameter>
>          <name>maxWait</name>
>          <value>100</value>
>      </parameter>
>      <parameter>
>          <name>validationQuery</name>
>          <value>SELECT MAX(id) FROM Users</value>
>      </parameter>
> </ResourceParams>
>
> I haven't had a single problem with this setup under any of the latest
> 4.1.x releases.
>
> Jake
>
> At 01:36 PM 11/13/2002 +0900, you wrote:
>
> >Neither repackaging the jar without the  javax.sql classes, nor just
> >placing one copy in common/lib worked. Another person suggested I use
> >ojdbc14.jar instead of classes12.jar, but this didn't work either. So, now
> >I'm looking into the Orion server....
> >
> >
> >
> >
> >Extranet
> >[EMAIL PROTECTED] - 11/12/2002 10:47 PM
> >
> >
> >Please respond to [EMAIL PROTECTED]
> >To:   tomcat-user
> >
> >cc:
> >
> >
> >Subject:  Re: Cannot create Oracle driver not matter what I do!
> >
> >
> >On a related note, There may also be problems with the classes12 file -
> >for some unknown reason, it contains the javax.sql package. I have seen
> >cases where JDK 14x just flat refuses to load it. You may want to unzip
> >the jar, remove those classes and repackage it without them.
> >
> >Larry
> >
> > >>> [EMAIL PROTECTED] 11/11/02 21:05 PM >>>
> >Don't put it everywhere. I've seen things break consistently when put in
> >
> >more than one classloader. Put it in your commons/lib directory. I'm
> >using
> >this and it works just fine under 4.0.4. Can you verify that you can
> >reproduce the problem under 4.0.4?
> >
> > >
> > > All attempts to create an Oracle database pool in 4.1.12 have failed.
> > >
> > > java.sql.SQLException: Cannot create JDBC driver of class
> > > 'oracle.jdbc.driver.OracleDriver'
> > >         at
> > > org.apache.commons.dbcp.BasicDataSource.createDataSource(Unknown
> > > Source) at
> > > org.apache.commons.dbcp.BasicDataSource.getConnection(Unknown
> > > Source) at
> > >
> 
>>com.opensymphony.module.user.provider.jdbc.JDBCCredentialsProvider.list(JDBCCredentialsProvider.java:40)
> >
> > > at
> > >
> >com.opensymphony.module.user.UserManager.getEntities(UserManager.java:288)
> > > at
> > >
> >com.opensymphony.module.user.UserManager.getUsers(UserManager.java:127)
> > > etc
> > >
> > > What I've tried:
> > >
> > > 1. Renamed classes12.zip to classes12.jar.
> > > 2. Put it EVERYWHERE, under every lib directory in the Tomcat
> >directory
> > > structure. 3. Added it to the CLASSPATH (in setclasspath.sh)
> > >
> > >  Prove to me that I am making the right decision in moving from
> >WebLogic
> > >  to Tomcat for a smal project!
> > >
> > > Ira
> > >
> > >
> > >
> > >
> > > This message and any attachments (the "message") is
> > > intended solely for the addressees and is confidential.
> > > If you receive this message in error, please delete it and
> > > immediately notify the sender. Any use not in accord with
> > > its purpose, any dissemination or disclosure, either whole
> > > or partial, is prohibited except formal approval. The internet
> > > can not guarantee the integrity of this message.
> > > BNP PARIBAS (and its subsidiaries) shall (will) not
> > > therefore be liable for the message if modified.
> > >
> > >                 ---------------------------------------------
> > >
> > > Ce message et toutes les pieces jointes (ci-apres le
> > > "message") sont etablis a l'intention exclusive de ses
> > > destinataires et sont confidentiels. Si vous recevez ce
> > > message par erreur, merci de le detruire et d'en avertir
> > > immediatement l'expediteur. Toute utilisation de ce
> > > message non conforme a sa destination, toute diffusion
> > > ou toute publication, totale ou partielle, est interdite, sauf
> > > autorisation expresse. L'internet ne permettant pas
> > > d'assurer l'integrite de ce message, BNP PARIBAS (et ses
> > > filiales) decline(nt) toute responsabilite au titre de ce
> > > message, dans l'hypothese ou il aurait ete modifie.
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > > <mailto:tomcat-user-unsubscribe@;jakarta.apache.org> For additional
> > > commands, e-mail: <mailto:tomcat-user-help@;jakarta.apache.org>
> >
> >
> >
> >
> >--
> >To unsubscribe, e-mail:
> ><mailto:tomcat-user-unsubscribe@;jakarta.apache.org>
> >For additional commands, e-mail:
> ><mailto:tomcat-user-help@;jakarta.apache.org>
> >
> >
> >
> >--
> >To unsubscribe, e-mail:   <
> >mailto:tomcat-user-unsubscribe@;jakarta.apache.org>
> >For additional commands, e-mail: <
> >mailto:tomcat-user-help@;jakarta.apache.org>
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >This message and any attachments (the "message") is
> >intended solely for the addressees and is confidential.
> >If you receive this message in error, please delete it and
> >immediately notify the sender. Any use not in accord with
> >its purpose, any dissemination or disclosure, either whole
> >or partial, is prohibited except formal approval. The internet
> >can not guarantee the integrity of this message.
> >BNP PARIBAS (and its subsidiaries) shall (will) not
> >therefore be liable for the message if modified.
> >
> >                 ---------------------------------------------
> >
> >Ce message et toutes les pieces jointes (ci-apres le
> >"message") sont etablis a l'intention exclusive de ses
> >destinataires et sont confidentiels. Si vous recevez ce
> >message par erreur, merci de le detruire et d'en avertir
> >immediatement l'expediteur. Toute utilisation de ce
> >message non conforme a sa destination, toute diffusion
> >ou toute publication, totale ou partielle, est interdite, sauf
> >autorisation expresse. L'internet ne permettant pas
> >d'assurer l'integrite de ce message, BNP PARIBAS (et ses
> >filiales) decline(nt) toute responsabilite au titre de ce
> >message, dans l'hypothese ou il aurait ete modifie.
> >
> >
> >--
> >To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@;jakarta.apache.org>
> >For additional commands, e-mail: <mailto:tomcat-user-help@;jakarta.apache.org>

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

Reply via email to