1. Connect to MYSQL on the remote host. Assuming that the IP of the remote host is: 110.110.110.110, the user name is root, and the password is 123, then type the following command:
mysql -h110.110.110.110 -u root -p dbname; (Note: There is no need to add between u and root Spaces, the same for others)
dbname can directly select the database you use, or not.
2. MySQL common commands to
view databases: show databases;
use a database: use dbname;
view tables: show tables;
exit MYSQL commands: exit
3. Edited statements need to end with a semicolon (;)