首页 > 技术文章 > mysql 5.7 修改密码

Springmoon-venn 2017-09-10 11:41 原文

  mysql 5.7 ,user表就没有password 这个字段了。

update user set password=password('12345678') where user='root' and host='localhost'; 

这样当然就改不了密码了。

 

update user set authentication_string=password('12345678') where user='root' and Host = 'localhost';
flush privileges;

 

尴尬。

推荐阅读