📞 0339-0387701 (WhatsApp) Contact

« Back to Database & Data Handling (NCCIA)

What is ON UPDATE CASCADE?

A. It prevents updates
B. When a child is updated, the parent is updated
C. When a parent key is updated, child foreign key values are updated automatically ✅
D. When a parent is deleted, children are deleted

Correct Answer: C. When a parent key is updated, child foreign key values are updated automatically

Explanation

When a parent primary key value changes, ON UPDATE CASCADE updates the matching foreign key values in child rows automatically.