mySQL在删除行为上的默认值
Default Behavior
MySQL's default ON DELETE behavior is to enforce referential integrity, preventing any change to the parent table that would break the relationship with child tables.这是通过或限制
Other OptionsMySQL offers additional options to handle ON DELETE events:
SET NULL: Deletes the parent row and sets the foreign key in the child table to NULL,如果未声明为null。
cascade:删除父行,并自动删除子表中的依赖行。
问题:免责声明: 提供的所有资源部分来自互联网,如果有侵犯您的版权或其他权益,请说明详细缘由并提供版权或权益证明然后发到邮箱:[email protected] 我们会第一时间内为您处理。
Copyright© 2022 湘ICP备2022001581号-3