connect mysql to local server code example
Example 1: mysql cli connect with password
mysql --user=root --password=mypass
Example 2: connect to mysql localhost from the mysql shell
\connect root@localhost:3306
mysql --user=root --password=mypass
\connect root@localhost:3306