清空具有外键约束的表时
异常:ERROR 1701(42000)
ERROR 1701 (42000): Cannot truncate a table referenced in a foreign key constraint (`
解决方法:
mysql> SET foreign_key_checks=0;
删除后
mysql> SET foreign_key_checks=1;
转载随意~:陶醉 » 清空具有外键约束 ERROR 1701
清空具有外键约束的表时
异常:ERROR 1701(42000)
ERROR 1701 (42000): Cannot truncate a table referenced in a foreign key constraint (`
解决方法:
mysql> SET foreign_key_checks=0;
删除后
mysql> SET foreign_key_checks=1;
转载随意~:陶醉 » 清空具有外键约束 ERROR 1701