Hibernate. 2 functions : simpleSave() , saveWithCascade() . can it be done ? and how ?
- by Blitzkr1eg
I have a scenario in which i have:
A parent class Parent which has some simple properties (int, String, etc) and 2 set of children.
Set childrenA;
Set childrenB;
Could i make a save function for parent simpleSave(Parent p) that will save/persists only the parent properties in the database and have a function saveWithCascade(Parent p) that will cascade to its children ?