Hi,
Hibernate has built-in "cascade" options for one-to-one/one-to-many relations, but how do these related to the database's own CASCADE actions?
For example, if I have already defined a foreign key in a table with ON DELETE CASCADE ON UPDATE CASCADE, do I really need to define cascade="delete" in Hibernate as well? And what would happen if I did tell Hibernate to cascade deletes, and the database already deleted the children?
And will Hibernate create INSERT/UPDATE statements for child collections when I use session.save(Parent)?
|