How do I install command line MySQL client on mac?
If you have already installed MySQL from the disk image (dmg) from http://dev.mysql.com/downloads/), open a terminal, run:
echo 'export PATH=/usr/local/mysql/bin:$PATH' >> ~/.bash_profile
then, reload .bash_profile
by running following command:
. ~/.bash_profile
You can now use mysql
to connect to any mysql server:
mysql -h xxx.xxx.xxx.xxx -u username -p
Credit & Reference: http://www.gigoblog.com/2011/03/13/add-mysql-to-terminal-shell-in-mac-os-x/
install MySQLWorkbench, then
export PATH=$PATH:/Applications/MySQLWorkbench.app/Contents/MacOS