This paper summarizes and records the basic commands for simple and common MySQL operations in the cmd window.
command to stop the MySQL database service
1. (cmd) command line
Startup: net start MySQL stop: net stop MySQL
2. Manual: 1. Use the shortcut key Ctr+alt+delete = "2. Start Task Manager =" 3. Enter service = "4. Find MySQL to start/close
3. Log in/out of MySQL system
Login: Mysql-h Server path-u login---host= server address--user= user name--port= Port---hlocalhost-uroot---host= Hlocalhost--user=root--port=3066 --password=123456//(Note: If the system environment is set well)
4. Backup and Recovery
// 4.1 Backup: Syntax: mysqldump-h server address-u login name-P databasename >-hlocalhost-uroot db>e:/db.sql// 4.2 Restore: Syntax: mysql-h server address-u login name-P databasename <-hlocahost-uroot-p db2<e:/db.sql
Basic operation of system operation of MySQL database