I have a user object that contains many persons in a one-to-many bag relationship.
The relationship is set up as follows: // USER class /** * @hibernate.bag name="persons" lazy="false" cascade="save-update" * @hibernate.collection-key column="user_id" * @hibernate.collection-one-to-many class="org.appfuse.model.Person" */ public List getPersons(){..... private Long userId; /** * @hibernate.property column="user_id" */ public Long getUserId(){ return userId; So the person table has a user_id column that tells me what user the person belongs to. Whenever I edit the profile of the user, the persons disappear from the users person list because in the DB the user_id column for the person gets set to NULL. I am not sure why this is happening. I think it may be the cascade options. Also, if I make changes to the user object, how can I get those changes in the DAO, SERVICE and WEB layer without changing whats already there... using appgen. Any direction would be appreciated. Thanks. ~rk -- View this message in context: http://www.nabble.com/Parent-object-updates-child-object-in-one-to-many-tf3229257s2369.html#a8972104 Sent from the AppFuse - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]