MySQL 5.7.18更改密码是出现Unknowncolumn'password'in'fieldlist'错误怎么办?

数据库教程 2020-06-14 12:22:26 21

导读

出现此错误的原因是mysql5.7数据库下已经没有password这个字段了,password字段被改成了:authentication_string所以更改为以下字段在运行即可:update mysql.user set authentication_string=password('123') where user='root';……

出现此错误的原因是mysql 5.7数据库下已经没有password这个字段了,password字段被改成了:

authentication_string

所以更改为以下字段在运行即可:

update mysql.user set authentication_string=password('123') where user='root';


1253067 TFnetwork_cn