Hello Dennis, Monday, May 06, 2002, 11:34:07 PM, you wrote:
If the cmr field isn't set, you should get null as a result of get method invocation. DM> This is concerning JBoss-3.0 on Branch_3_0 latest CVS DM> linux/jdk1.3.1 DM> On Mon, 2002-05-06 at 14:10, Dennis Muhlestein wrote: >> I have a situation where an account can have one or none of an another >> entity bean in a relationship. >> >> I've defined it below as a one-one relationship. This works fine if the >> billingInfo exists, but if it doesn't and I call getBillingInfo from the >> account, I still get an EntityBean Interface back. (No Exception >> occurs) Then, when I try to access or set something on the billingInfo >> interface, I get NoSuchEntityException from jboss. >> >> Should I use one-many instead?? Shouldn't I get null back or something >> instead of an interface to the ejb when the billingInfo doesn't yet >> exists? If this is the correct functionality, then how to I know if a >> billing info record exists or not yet? Is it possible to remove the >> billingInfo record in this case or is that against the law in a one-one >> relationship? >> >> Thanks for any comments. >> Dennis >> >> <ejb-relation> >> <description>One Account has One/None >> BillingInfo</description> >> <ejb-relation-name>Account-BillingInfo</ejb-relation-name> >> <ejb-relationship-role> >> >> <ejb-relationship-role-name>AccountToBillingRole</ejb-relationship-role-name> >> <multiplicity>One</multiplicity> >> >> ><relationship-role-source><ejb-name>AccountEJB</ejb-name></relationship-role-source> > >> <cmr-field> >> <cmr-field-name>billingInfo</cmr-field-name> >> </cmr-field> >> </ejb-relationship-role> >> <ejb-relationship-role> >> >> <ejb-relationship-role-name>BillingToAccountRole</ejb-relationship-role-name> >> <multiplicity>One</multiplicity> >> <relationship-role-source> >> <ejb-name>BillingInfoEJB</ejb-name> >> </relationship-role-source> >> </ejb-relationship-role> >> </ejb-relation> -- Best regards, Alex mailto:[EMAIL PROTECTED] _______________________________________________________________ Have big pipes? SourceForge.net is looking for download mirrors. We supply the hardware. You get the recognition. Email Us: [EMAIL PROTECTED] _______________________________________________ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user