Referential Integrity Options
Relationships › Referential Integrity › Referential Integrity Options
Referential Integrity Options
Referential integrity rules vary depending on:
- Whether or not the entity is a parent or child in the relationship
- The database action that is implemented
As a result, in each relationship there are six possible actions for which referential integrity can be defined:
- PARENT INSERT
- PARENT UPDATE
- PARENT DELETE
- CHILD INSERT
- CHILD UPDATE
- CHILD DELETE
The following figure shows referential integrity rules in the EMPLOYEE‑PROJECT model:
The referential integrity rules captured in the figure show the business decision to cascade all deletions in the PROJECT entity to the PROJECT-EMPLOYEE entity. This rule is called PARENT DELETE CASCADE, and is noted in the figure by the letters D:C placed at the parent end of the specified relationship. The first letter in the referential integrity symbol always refers to the database action: I(Insert), U(Update), or D(Delete). The second letter refers to the referential integrity option: C(Cascade), R(Restrict), SN(Set Null), and SD(Set Default).
In the figure, no referential integrity option was specified for PARENT INSERT, so referential integrity for insert (I:) is not displayed on the diagram.
| Copyright © 2013 CA. All rights reserved. |