This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes EJB and other Java EE Technologies and the fly likes Binding of Entity Bean and database Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Binding of Entity Bean and database" Watch "Binding of Entity Bean and database" New topic
Author

Binding of Entity Bean and database

Himal Chuli
Ranch Hand

Joined: Aug 06, 2002
Posts: 118
hi folks,
i am trying hard to get access to database from EJB in WSAD. here is what i am doing,
I have a Oracle Database named "marsh"
create an EntityBean and map it to RDB
Target Database: Oracle8i
Database Name: marsh
Also,
configured DataSource in server perspective as follows;
in DataSource dialog:
name=HelloWorldDataSource
JNDI Name=jdbc/OracleDataSource
(am not sure if how this JNDI gets connected to my Datasource 'marsh')
then i tried Binding this DataSource with EntityBean(CMP) as follows:
opening the ejb-jar.xml in EJB Extension Editor and selecting Binding Tab
JNDI Name=hello/HelloWorldEntity
DataSource JNDI=jdbc/DataSource
and saved them.
i tried Run On Server by right clicking my HelloWorldSession Bean which actually access EntityBean. it says "Publishing failed" and
"The data source "jdbc/OracleDataSource" in the "helloworldproject" jar is not defined in the server configuration. Define the data source in the configuration, and

"The data source "jdbc/OracleDataSource" in the "helloworldEntity" jar is not defined in the server configuration. Define the data source in the configuration,
i don't know what is this mean? what wrong am i doing? please help me.
thank.


Himal
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Binding of Entity Bean and database
 
Similar Threads
eclipse + postgreSQL + JBoss
URGENT! problem with Oracle ConnectionPoolDataSource
Looking up Datasource object from a stateless session bean in WSAD 5.0....
Help!!! I can't get BMT working with Orion and MS SQL Server
Can't access JDBC Datasource using JNDI