How to change the mysql root Password in windows, mysqlroot
It is very painful for the mysql database to forget the root password. This article describes how to solve the problem of forgetting the root password for the mysql server in windows.
1. Disable MySQL Service
Window + r run input net stop mysql
2. Open the command line in the bin directory of mysql
Shift + right-click in the blank space ----> Find and open the command window here
3. Enter mysqld-nt -- skip-grant-tables
The message ended with "set to off" indicates that the operation is successful.
4. Open another command line in the same location, enter mysql, and press Enter.
5. Enter use mysql;
6. update user set password = password ("new password") where user = "root ";
7. flush privileges;
8. quit;
9. Start the mysql Service
Run net stop mysql
10. Go to the cmd test,
Mysql-uroot-p
The above section describes how to change the mysql root Password in windows. I hope it will be helpful to you. If you have any questions, please leave a message, the editor will reply to you in a timely manner. Thank you very much for your support for the help House website!