Forums Register Login

EJB creates new table in database.........

+Pie Number of slices to send: Send
Hi ,

I am developing small EJB CMP 2.0 application.
I have one table named "employeemaster" in my database & for dat table i ve created EJB named "EmpMasterBean" successfully. Now when i m deploying n running EJB, It creates a table named "EmpMasterBean" in my database, which is my bean's name. But I don't want hare to create new table, instead i want to insert data into already existing table "employeemaster" for which i ve created above bean.

How to do this???

Please help me.

Thanx in advance...
+Pie Number of slices to send: Send
Which AppServer you are using?
In CMP there will be one more Deploymwnt Descriptor e.g If its weblogic then, name of Deployment Descriptor is weblogic-cmp-rdbms-jar.xml,which specifies Table name & mapping info of cmp fields & db columns etc.
+Pie Number of slices to send: Send
Hi,
Thanx for trying on this.
I got my mistake. I m using JBOSS4.0.3 & I was missing <table-name> tag in my jbosscmp-jdbc.xml file. Now it working fine.
Thanx again for trying.

Prash
These are not the droids you are looking for. Perhaps I can interest you in a tiny ad?
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 715 times.
Similar Threads
How to write following SQL query in EJB QL????
howto use a sequence as primary key in entity beans
Getting existing data with CMP
Problem with OneToOne relationship
Persisting a class to two tables with Hibernate
More...

All times above are in ranch (not your local) time.
The current ranch time is
Apr 16, 2024 06:32:39.