MySQL修改密码报错:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'IDENTIFIED BY '123456'' at line 1
错误原因:
mysql> set password for 用户名@localhost = password('新密码');
改为:
ALTER USER 'root'@'localhost' IDENTIFIED BY '新密码';