This content has been marked as final.
Show 2 replies
-
1. Re: Bidirectional Cascade
waynebaylor Jun 24, 2007 9:18 AM (in response to thepriz)The cascade setting will only work in one direction, so if you put it on the OneToMany relationship you can remove entities from the collection without fear of deleting the parent.
As for the second question, if you have CascadeType.ALL set, then you won't be able to set the ManyToOne side because it will be deleted when the other side is deleted.
Hope that helps :) -
2. Re: Bidirectional Cascade
thepriz Jun 24, 2007 3:03 PM (in response to thepriz)Yes, that helps a lot. It may explain why I was seeing some problems. I will have to experiment more.