the SET password for root @localhost = password ( ' your password ' );
or
the SET password for ' root ' @ ' localhost ' = password ( ' MyNewPass4! ' );
Tip: mysql database command to change the root user password prompt ERROR 1133 (42000): Can not find any matching row in the user table error
to solve:
use mysql; select Host,User from user;
The reason: The main reason is to modify the password条件不否
- The
set password for 'root'@'localhost'=password('MyNewPass4!');
codelocalhost
modification%
, and databaseHost
field values agreeset password for 'root'@'%'=password('MyNewPass4!');
- Refresh
flush privileges;