MySQL workbench safe mode 해제하기

Error Code: 1175. You are using safe mode and you tried to update a table without a WHERE that uses a KEY column To disable safe mode.


MySQL workbench에서 table을 UPDATE나 DELETE할 때 where 조건절을 쓰지 않고 할 경우 위처럼 에러코드 메시지가 나오면서 쿼리를 수행하지 않게됩니다.


MySQL Safe mode off


MySQL workbench safemode off


Edit - Preferences 클릭




MySQL workbench safemode off


SQL Editor - Safe Updates 체크 박스 해제한 후 OK 눌러주세요.




MySQL workbench safemode off


마지막으로, Query - Reconnect to Server를 클릭하고 나면 UPDATE, DELETE를 사용할 수 있습니다.



또는 아래 쿼리를 입력하면 위 설정 상관없이 바로 해제가능합니다.


SET SQL_SAFE_UPDATES = 0;



출처 : https://stackoverflow.com/questions/11448068/mysql-error-code-1175-during-update-in-mysql-workbench



댓글

Designed by JB FACTORY