A "safe mode" error occurs when running dbscripts

Issue Symptoms

 

When running database scripts (to create or update), the following error occurs:

"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"

 

Solution

 

You must disable this safe mode by passing the parameter: SET SQL_SAFE_UPDATES = 0; in the MySql configuration file.

 

To do this, use the tomcat service and stop mysql:

  1. Edit the my.ini configuration file
  2. Search for "SQL_SAFE_UPDATES".
  3. Make the change
  4. Save and restart services.

Alternative solution

 

If you are using the MySQL workbench :

  1. Connect to your instance
  2. Go to Edit > Preferences
  3. Uncheck "Safe updates
  4. updates are taken into account after reconnection.

 

Support


If you require assistance to resolve the problem, please ask for support. (See Requesting Support)

Setup & maintenance
Views: 6