使用mysql官方工作台,当update、delete、truncate(特别是对于无主键)时,提示:
Error Code: 1175. You are using safe update mode and you tried to update a table without a WHERE that uses a KEY column To disable safe mode, toggle the option in Preferences -> SQL Queries and reconnect. 0.000 sec
可通过下图进行操作修改,修正后,请重启工作台。
或通过在执行脚本前增加SET SQL_SAFE_UPDATES = 0;解除安全模式