Of course I did mean .jar
>I have copied the DB2 jdbc driver file to $CATALINA_HOME/common/lib (I
> copied it both as .zip and .tar as some web resources suggested tomcat
would
> only recognise it as .tar)
- Original Message -
From: "Alan Nesbitt" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, August 17, 2003 8:25 PM
Subject: Cannot Solve "jdbc is not bound is this Context" problem
> We have been trying for over a week to solve this problem. It doesn't help
> that we haven't used tomcat before, but our application works fine on
> WebSphere. So I guess that it some configuration that we are missing.
> We are trying to configure tomcat (4.1.24) to do a jndi lookup of a
> DataSource which is a db2 jdbc app driver.
>
> The Tomcat server.xml had a sample jdbc configuration which was modified
to
> the following...
>
> type="javax.sql.DataSource"/>
>
> user
> password
> driverClassName
> COM.ibm.db2.jdbc.app.DB2Driver
> driverName
> jdbc:db2:SWPPDB2
>
>
> The web.xml includes
>
>
> jdbc/SURESWIT
> javax.sql.DataSource
> Container
>
>
> The Java code performs the following :-
>
> if (ds == null)
> {
> try {
>Context ctx = new InitialContext();
> ds = (javax.sql.DataSource) ctx.lookup(("jdbc/SURESWIT");
> ctx.close();
> }
> catch (Exception e)
> {
> logger.text( IRecordType.TYPE_ERROR_EXC,
> className,
> "init(ServletConfig)",
>"Naming service exception:" + e.toString());
>}
> }
>
> When the above code runs it throws the following exception
> init(ServletConfig) Naming service
> exception:javax.naming.NameNotFoundException:
> Name jdbc is not bound in this Context
>
> I have copied the DB2 jdbc driver file to $CATALINA_HOME/common/lib (I
> copied it both as .zip and .tar as some web resources suggested tomcat
would
> only recognise it as .tar)
>
> ANY and I mean ANY help would be greatly appreciated. Even if it's to say
it
> doesn't work with tomcat.
>
> Many thanks Alan
>
>
> -
> 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]