try  "java:comp/env/mySQLDS" in your lookup.

Wes

-----Original Message-----
From: Roman Brouk [mailto:[EMAIL PROTECTED]]
Sent: Friday, April 27, 2001 5:06 PM
To: [EMAIL PROTECTED]
Subject: [JBoss-user] Please Help... i have been working on this problem
for 5 days


I am using BMP. The question is how to access DataSource that represents
connection pool.

on start up JBOSS says that "[mySQLDS] XA Connection pool mySQLDS bound to
java:/mySQLDS [mySQLDS] ".  I have entries in jboss.jcml.

But in entity bean which I retrieve from JNDI, when I get connection:

try{
            InitialContext jndiContext = new InitialContext();
            javax.sql.DataSource ds = (javax.sql.DataSource)
jndiContext.lookup("java:/mySQLDS");
            con = ds.getConnection();
        }catch(Exception ex){
            System.out.println("Looking for DataSource: " +
ex.getMessage());
        }


I get message that mySQLDS is not bound.



ANY IDEAS?  THANKS for your time and help.

-ROMAN BROUK


_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to