Multiple choice technology databases

Which of the following deletion rules on CREATE TABLE will allow parent table rows to be deleted if a dependent row exists?

  1. ON DELETE RESTRICT

  2. ON DELETE NO ACTION

  3. ON DELETE SET NO VALUE

  4. ON DELETE CASCADE

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

ON DELETE CASCADE allows deletion of parent rows and automatically deletes all dependent child rows, maintaining referential integrity. RESTRICT and NO ACTION prevent deletion if dependents exist. SET NO VALUE is not a valid deletion rule.