MySQL Workbench – Error Code: 1175. You are using safe update mode

MySQL Workbench – Error Code: 1175. You are using safe update mode

When you execute the update/delete request in MySQL workbench and you got the message error as:

You are using safe update mode and you tried to update a table without a WHERE that uses a KEY column

And in MySQL Workbench also mention how we solve this issue as well by following message:

To disable safe mode, toggle the option in Preferences -> SQL Editor -> Query Editor and reconnect

Every found that kind of error when trying to update rows in MySQL? It’s because you tried to update a table without a WHERE that uses a KEY column. In my case, I don’t use even WHERE clause:

1
2
3
delete from order_detail;
 
delete from order;

Any way, the quick fix is to add SET SQL_SAFE_UPDATES=0; before your update/delete query.

1
2
3
4
SET SQL_SAFE_UPDATES=0;
delete from order_detail;
 
delete from order;

Or follow what MySQL Workbench mentioned as here:

To disable safe mode, toggle the option in Preferences -> SQL Editor -> Query Editor and reconnect

Here is the screenshot in MySQL Workbench 5.2.40 CE

MySQL Workbench – Error Code: 1175. You are using safe update mode

MySQL Workbench 5.2 – Error 1175

 

It might help for those who first experience with MySQL Workbench.

If any possibly solutions found, just drop here in the comment.

相关文章:

  • 2021-11-03
  • 2022-03-01
  • 2022-12-23
  • 2021-08-09
  • 2021-10-18
  • 2022-02-15
  • 2022-01-05
猜你喜欢
  • 2021-05-19
  • 2021-09-24
  • 2021-09-30
  • 2022-12-23
  • 2021-09-30
  • 2021-06-10
  • 2022-12-23
相关资源
相似解决方案