Product ------FK----> Purchase List
If the product on the purchase list is deleted, the purchase list is supposed to be deleted.
Is it the right way not to delete the purchase list?
Or is it right to delete the original purchase list?
django database postgresql mysql redis
It depends on the plan rather than the development logic, shouldn't we keep the purchase list? Or I think it's also a way not to delete the product itself.
I understand that you don't usually delete it. There are quite a few cases like this, so they rarely use reference constraints.
© 2024 OneMinuteCode. All rights reserved.