mysql 7.11 修改密码错误 ERROR 1054 (42S22)

Posted linchw3

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了mysql 7.11 修改密码错误 ERROR 1054 (42S22)相关的知识,希望对你有一定的参考价值。

mysql> use mysql;
Database changed
mysql> update user set password=password(‘123456‘) where user=‘root‘;
ERROR 1054 (42S22): Unknown column ‘password‘ in ‘field list‘
mysql>

晚上被这个问题折腾了好久,最后发现window下这个版本的mysql密码列是authentication_string,所以正确的写法是:

mysql>update mysql.user set authentication_string=password(‘123456‘) where user=‘root‘ and Host =‘localhost‘;

问题解决

以上是关于mysql 7.11 修改密码错误 ERROR 1054 (42S22)的主要内容,如果未能解决你的问题,请参考以下文章