IT lexicon › Database › Cascading delete

Cascading delete

Database På svenska → Updated: 2026-11-11

Referential integrity action: when a row is deleted, all dependent rows are automatically removed as well.

A customer is deleted → all their orders disappear automatically via ON DELETE CASCADE. Alternatives: RESTRICT (prevent deletion if dependents exist) and SET NULL (null out the foreign key). Powerful but risky—one delete can wipe out huge subtrees unintentionally. CODASYL systems from the 1970s lacked this safety mechanism entirely; cascades had to be coded by hand.

← Back to the lexicon