Which option describes Delete Set-to-Null?

Prepare for your Database Systems Test. Use flashcards and multiple-choice questions, each question with hints and explanations. Ace your exam!

Multiple Choice

Which option describes Delete Set-to-Null?

Explanation:
Delete Set-to-Null tests the on delete action where removing a row from the parent table leaves the child rows intact but breaks their link to the parent by setting the referencing foreign key to NULL. This only works if the foreign key column is nullable; otherwise the delete would violate the constraint. It differs from cascade delete (which removes child rows) and from restrict/no action (which would prevent the delete if there are dependents). So the behavior described—when the parent is deleted, the foreign key values in child records are set to NULL—is exactly what this option conveys.

Delete Set-to-Null tests the on delete action where removing a row from the parent table leaves the child rows intact but breaks their link to the parent by setting the referencing foreign key to NULL. This only works if the foreign key column is nullable; otherwise the delete would violate the constraint. It differs from cascade delete (which removes child rows) and from restrict/no action (which would prevent the delete if there are dependents). So the behavior described—when the parent is deleted, the foreign key values in child records are set to NULL—is exactly what this option conveys.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy