Enforcement of delete rules

When you delete a record from a parent file, the system checks the dependent file for any dependent records (matching non-null foreign key values). If the system finds any dependent records, the delete rule determines the action that is taken.

If part of the delete rule enforcement fails, the entire delete operation fails and all associated changes are rolled back. For example, a delete cascade rule causes the database to delete ten dependent records, but a system failure occurs while deleting the last record. The database will not allow deletion of the parent key record, and the deleted dependent records are re-inserted.

If a referential constraint enforcement causes a change to a record, the associated journal entry will have an indicator value noting that a referential constraint caused the record change. For example, a dependent record that is deleted by a delete cascade rule will have a journal entry indicator which indicates that the record change was generated during referential constraint enforcement.