For unzipped version 5.7.16 (this version used by bloggers, some commands fail in some low versions)
First, initialize the data directory (uncompressed version of the data directory after decompression)
Mysqld--initialize-insecure--user=mysql
Second, modify the root password, connect to the database after use MySQL
1. Update Mysql.user set Authentication_string=password (' 123qwe ') where user= ' root ' and Host = ' localhost ';
The new version of MySQL has no password field, but the encrypted user password is stored in the Authentication_string field, so many methods on the Web is not available, after the execution of the service will be effective after the restart
You will need to restart the service to take effect whenever you change your password.
2, mysqladmin–u user name –p old password Password new password
Third, if you forget the root password (not connected to the database to modify the root password)
1. The administrator runs the first cmd, enter net stop MySQL to close the MySQL service, and then enter Mysqld--skip-grant-tables to skip the password
2, keep the cmd of the previous step does not close, the administrator runs another cmd, directly enter Mysql-u root-p Enter, display the input password, the direct return can be password-free login
3, you can change the root password in the second cmd (see two).
Note: The process MySQL does not have a net start MySQL operation.
Four, net start MySQL when there is no start
Check to see if it is started, or if there is a mysqld.exe process running in the process.
MyEclipse Database Explorer to establish MySQL connection error
Testdriver error while performing database login with the testmysql driver check your URL. Check for URL connection no problem. The problem is with the driver classname, which is automatically populated with this name after the add MySQL jar package is called Com.mysql.fabric.jdbc.FabricMySQLDriver. This is wrong and should
Com.mysql.jdbc.Driver. You can resolve the problem that indicates that the error is not connected.
Vi. MySQL Utility commands
1. Enquiry
(1), starting from the No. 0 row, take 3 lines
SELECT * FROM student limit 0,3
Tips, troubleshooting, and Utility commands for installing MySQL database (continuous update)