aspose file tools*
The moose likes EJB and other Java EE Technologies and the fly likes Can a CMP EJB be a CMP field inside another CMP EJB Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Can a CMP EJB be a CMP field inside another CMP EJB" Watch "Can a CMP EJB be a CMP field inside another CMP EJB" New topic
Author

Can a CMP EJB be a CMP field inside another CMP EJB

Sanjeev Verma
Ranch Hand

Joined: Aug 24, 2000
Posts: 87
Hi all
Lets say there is a Person CMP EJB and a Address CMP EJB.
1. Can the person EJB have a cmp field as Address EJB? (In EJB 1.1)
2. If yes, what will be the create statement for the table that will hold the person data look like. I basically mean to ask the data type of the Address column.
3. If this was with reference to EJB 2.0, can I still have point 1? I DO NOT mean/want to use <cmr-field>.
Thanx
Sanjeev
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16019
    
  20

You'd do better to use an Entity bean acting as facade for 2 distinct CMP beans. In the case of CMP, your DBMS is not going to properly handle serialization of and embedded EJB into the DBMS.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Can a CMP EJB be a CMP field inside another CMP EJB