Howdy,
Did you try creating the datasource by hand using the instructions on
the JNDI How-To
(http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource-example
s-howto.html) page?  If so, what happened?

As an aside, you may wish to revisit the log4j introductory manual for
some tips on how to better use log4j ;)

Yoav Shapira
Millennium ChemInformatics


>-----Original Message-----
>From: Softwareentwicklung Hauschel
[mailto:[EMAIL PROTECTED]]
>Sent: Thursday, January 23, 2003 12:00 PM
>To: [EMAIL PROTECTED]
>Subject: JNDI Problem
>
>Hey all,
>I've created a Datasource wit Tomcat Admin Tool.
>The JNDI Name is: jaxsdb.
>
>Now i want to load this resource:
>
>       public DataSource getds()
>       {
>               Category cat =
>Category.getInstance("de.hauschel.wapen.be.BEFactory");
>               cat.debug("->getds()");
>               try
>               {
>                       // Obtain our environment naming context
>
>                       Context initCtx = new InitialContext();
>
>                       Context envCtx = (Context)
>initCtx.lookup("java:comp/env");
>
>                       // Look up our data source
>
>                       DataSource ds =
(DataSource)envCtx.lookup("jaxsdb");
>
>                       cat.debug("<-getds()");
>                       return ds;
>
>               }
>               catch (NamingException e)
>
>
>                       cat.debug("EXCEPTION");
>                       cat.debug(e.getMessage());
>               }
>               cat.debug("<-getds()");
>               return null;
>       }
>
>But i always become the same NamingException: Name jaxsdb is not bound
in
>this Context
>
>Anybody knows the Problem ?
>
>thanks,Fredy
>
>
>--
>To unsubscribe, e-mail:   <mailto:tomcat-user-
>[EMAIL PROTECTED]>
>For additional commands, e-mail: <mailto:tomcat-user-
>[EMAIL PROTECTED]>


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

Reply via email to