File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes EJB and other Java EE Technologies and the fly likes I need big help!! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "I need big help!!" Watch "I need big help!!" New topic

I need big help!!

Herbert Maosa
Ranch Hand

Joined: May 03, 2000
Posts: 289
I have struggled for the past four days, tying to do what I thought was a simple thing, but I am now frustrated and I just dont know why things dont work the way I thought thy should.
I am trying to access a database using an entity bean with bean managed persitence. I am just lerning. So I have created a database, called <b> SampleDataBase</b>, running on <b>mysql server</b>. I have downloaded the necessary jdbc drivers for my server, and I can access the databse from an ordinary java application without a problem. I have configured my application server, (Sun Application Server ) to point to this driver correctly in the classpath.
I have an entity bean, in it I refer to my database resource as <b>"jdbc:env/comp/jdbc/MySampleDataBase".</b>
In the Application Server, I have created the Connection Pool, and I have a resource associated with it called <b>jdbc/SampleResource</b>
I have made the necessary maping of the coded <b>jdbc/MySampleResource</b> to <b>jdbc/MySampleDataBase</b>.
When I try to run my application client, I get a RemoteException that there is an error creating the database connection.
I have tried and tried and tried and tried. I have even tried to create a database in the Pointbase server that comes with the java app server, but I get the same problem.
I dont know if my situation is clear, but I need some one patient enough to help me move forward. Otherwise my study has stalled because I cant go on untill I get this done.
Herbert Maosa.
pavi kavi
Ranch Hand

Joined: Mar 01, 2001
Posts: 56
Before trying to use the connection of the database make sure in the application server the connection is getting created if not what is the exception its throwing?
Paste the exception here
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
subject: I need big help!!
It's not a secret anymore!