Max,
Thanks for clearing that up. I'll submit a feature request to the hibernate tools
project to adjust the cascade attribute so that it matches the database-defined behavior.
I'll also submit a request to the seam team for a mention of this behavior in the
"Getting started with Seam, using seam-gen" section of the reference.
BTW - just as an example of what can happen if one does not change the "default
behavior":
Delete a (sales) employee. This cascades to delete all of the customers associated with
that employee, which, in turn, cascades to delete all of the sales orders and line items
associated with that customer. Also, if the employee table has a self-referential foreign
key to identify the employee's boss, a whole chain of other employees (and their
customers and sales orders) can be deleted...
Stephen
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4104850#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...