Thanks you very much. Gonna try it the morning! 

Mtgglf

Nils

-----Original Message-----
From: Thomas Dudziak [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 26, 2005 3:36 PM
To: OJB Users List
Subject: Re: Storing of 1 to n relationship fails

The inverse-foreignkey specifies the field in the contained class
(Email in your case) that holds the primarykey value of the associated
container. Think of it as a back-reference.
The problem is that you specified the primarykey field of the
contained class to ve the inverse-foreignkey field, as well. This
leads to problems as OJB updates the value of the inverse-foreignkey
thus overwriting the primarykey value.
Simply add a separate field individualId to your Email class &
descriptor that has the same datatype as the id field of the
Individual class, and use this one for the inverse-foreignkey.

Tom

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to