CodePudding user response:
From the function, essentially no difference betweenBut the design of the trigger to delete is more complicated
CodePudding user response:
Is a kind of constraint of cascade deletion (constraint).The delete trigger is a trigger (trigger).
CodePudding user response:
Associated with the relationship between tables to processing, to the same database, design to establish good relations, can trigger across databases, is more flexibleCodePudding user response:
Cascading delete, it is only an option, and foreign key constraints that is dependent on foreign key of cascade deletion,The delete trigger, he can realize the function of many, depends on what statement is written by a user, use the trigger synchronization delete child table data, just a common applications,