☆ 8 r/databases ·by Priya ·2026-11-03 Foreign key ON DELETE CASCADE or manual cleanup? 1257 views I have orders with order_items. Cascade is convenient but one accidental delete could wipe years of data. Is manual cleanup worth the complexity? ⧉ Copy link⚑ Report
☆ 0 O Oskar ·2026-11-03#1 Cascade is fine when the child rows truly belong to the parent. The danger is when you add a foreign key to something you did not mean to cascade. ⧉ Copy link⚑ Report
☆ 0 P Priya ·2026-11-03#2 We need an audit trail even after deletion. Does that rule out cascade? ⧉ Copy link⚑ Report
☆ 0 A Aisha ·2026-11-03#3 Yes. Use soft delete on orders and keep cascade for genuinely dependent rows like items. Audit rows should never cascade with the business object. ⧉ Copy link⚑ Report
3 replies