MySQL Workbench Error 1175 Even With a “Where” Statement

后端 未结 4 1252
时光说笑
时光说笑 2021-01-29 07:27

I am running MySQL Workbench 6.3.8 b1228 CE (64-bit) in \"safe update mode\". I am trying to run a query with a \"WHERE\" statement, but it still returns \"Erro

4条回答
  •  后悔当初
    2021-01-29 07:57

    In Sql by default safe options is enabled which restricts the user from deleting or updating the data in table using inappropriate key.To turn of the safe update go to

    edit->preferences->sql editor and uncheck the safe update check box at the bottom of the preference window or even you can delete or update referencing the primary key.

    For Example: Let us consider we have table called user_details with four fields(name, number, email ,address) where name is the primary key. So your delete statement would look like this

    Delete from user_details where name="xxx";
    

    Note: Reconnect to the database after safe update is turned off. Even you can restart the server but reconnect itself works fine.

    Hope this solves your issue.

提交回复
热议问题