🌱 connecting to MySQL from the command line - Stack Overflow

Source
mysql -u USERNAME -pPASSWORD -h HOSTNAME -P PORTNUMBER DATABASE

Note that there is NO SPACE between -p and password

You can also not pass the password and be prompted for it

mysql -u USERNAME  -h HOSTNAME -P PORTNUMBER DATABASE -p
Made by Brandon . If you find this project useful you can donate.