From: Christian B. <c....@un...> - 2003-06-16 20:40:45
|
On 16 Jun (13:47), Rob Butler wrote: > 1) If I have a parent child relationship, and in the DB the child has the parents key, should the RI of that relationship be enforced in the DB? Of course, if you use the SchemaExport tool, Hibernate will even create the foreign key constraints for you. > 2) What about "business" referential integrity? If I were doing things the "old way" and using the business data as keys, the DB would perform lots of RI checking to make sure only "valid" rows could be inserted (rows where the primary key / foriegn key relationships were correct). Should these RI "rules" still be enforced in the database, or not? Don't do that. -- Christian Bauer c....@un... |