提示输入密码,因为现在是空,所以直接按回车。
然后输入“use mysql”,意思是使用mysql这个数据库,提示“Database changed”就行。
晚上被这个问题折腾了好久,最后发现window下这个版本的mysql密码列是authentication_string,所以正确的写法是:
mysql>update mysql.user set authentication_string=password('123456') where user='root' and Host ='localhost';
最后输入“flush privileges;”,不输入这个的话,修改密码的操作不会生效的。
然后输入“quit”退出。