Intermediate
Database Management Systems
Q61 / 100
What is a foreign key constraint and cascading?
Correct! Well done.
Incorrect.
The correct answer is B) Referential integrity enforcement with cascade options: ON DELETE CASCADE automatically deletes child rows when parent is deleted
B
Correct Answer
Referential integrity enforcement with cascade options: ON DELETE CASCADE automatically deletes child rows when parent is deleted
Explanation
ON DELETE CASCADE: deleting parent deletes all children. ON DELETE SET NULL: sets FK to NULL. ON DELETE RESTRICT (default): prevents parent delete if children exist. Cascading prevents orphaned records.
Progress
61/100