I have an entity A who has entity B.
Class Entity A
{
public EntityB;
}
Class Entity B
{
public Entity A;
}
Entity B has one to one relationship with A. I am trying to use cascade save,delete when entity A is saved so that I don't have to manually save entity B. It shpould be done automatically.
my mapping for entity B looks like:
<many-to-one name="EntityA" cascade="save-update"
column="EntityASomeProperty" class="EntityA" />
I not able to save entity B automatically when A is saved.