Home >Database >Mysql Tutorial >How to solve the problem that mysql is not an internal command?
Solution: 1. Right-click the "Computer" icon and select "Properties" in the menu that opens; 2. In the system interface, click "Advanced System Settings"; 3. In the "System Properties" pop-up window, click "Environment Variables"; 4. In the "System Variables" area of the "Environment Variables" pop-up window, select "Path" and click "Edit"; 5. In the "Edit Environment Variables" window that opens, fill in Enter the bin directory path in the Mysql installation directory and click "OK"; 6. Restart the cmd window.
The operating environment of this tutorial: windows10 system, mysql8 version, Dell G3 computer.
Sometimes I want to log in to the mysql server from the cmd window, but an error is reported, indicating that mysql is not an internal or external command
Solution: Open the computer's environment variables, select system variables, open Path, and add the bin directory path of mysql to it
Steps:
1. Right-click "Computer" ” icon, select “Properties” in the menu that opens
2. In the system interface, click “Advanced System Settings”
3. In the "System Properties" pop-up window, click the "Environment Variables" button
4. In the "Environment Variables" pop-up window, click "System Variables" " area, select "Path" and click "Edit"
5. In the "Edit Environment Variables" window that opens, fill in the bin directory path in the Mysql installation directory. , click "OK".
#6. Restart the cmd window.
Executemysql -u root -p
ok, you can log in!
[Related recommendations: mysql video tutorial]
The above is the detailed content of How to solve the problem that mysql is not an internal command?. For more information, please follow other related articles on the PHP Chinese website!