Consider a parent table P and a child table C with a foreign key referencing P. Which of the following statements correctly describes an operation that will NEVER violate the referential integrity constraint?
C
Step-by-Step Solution
Key idea: Referential integrity restricts the child table on insert/update and the parent table on delete/update. It does not restrict inserting into the parent.
Step 1: Analyze the operations based on the violation checklist.
Step 2: Deleting from P (referenced) -> Violates (orphans child).
Step 3: Inserting into C (invalid FK) -> Violates (points to non-existent parent).
Step 4: Inserting into P -> Safe. Adding a new parent does not break any existing child links.
Step 5: Updating PK in P (referenced) -> Violates (orphans child).
Answer: Inserting a tuple into P with a primary key value not referenced by C.