Hi all!
 
I am a newbie at EJB peculiar CMR and have a problem with a solved N:M relation. I have found a theoretical solution for this in the "EJB-Professional" Book, but don't know how to map it to a working EJB.
I have 3 Tables:
a) Order
b) Items
c) realtion between Order and Item (solved N:M), includes just the foreign keys of Order and Item
 
The book says, i need two EntityBeans OrderBean and ItemBean and one CMR-Field at OrderBean. With the statement 'SELECT OBJECT(o) FROM ORDER o, IN(o.item) i' I should get all orders with the corresponding items.
Now I don't know how to initialize the CMR-Field and and all the other EJB QL stuff. What kind of object will i receive, my opinion is an Order-Object, but where are the item informations?
Mybe someone send me a snip of his deployment descriptor and a code example, it will help me very much.
 
Sorry the newbie question, but i'm really stuck in this and there was no examplecode in the book.
 
Thanks a lot
CU
BJ
 
PS: I'm using JBOSS 3RC3 and Oracle 8i

Reply via email to