MySQL命令行自动补全——mycli安装
一、基于python安装pip
[root@db01 ~]# yum -y install python-pip python-devel
[root@db01 ~]# curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
[root@db01 ~]# python get-pip.py
二、安装mycli命令行工具
[root@db01 ~]# pip install --ignore-installed mycli
三、测试使用效果
[root@db01 ~]# mycli -uroot -p123.com
#使用mycli工具登录数据库
(2003, "Can't connect to MySQL server on 'localhost' ([Errno 2] No such file or directory)")
Failed to connect by socket, retrying over TCP/IP
mysql 5.7.28
mycli 1.20.1
Chat: https://gitter.im/dbcli/mycli
Mail: https://groups.google.com/forum/#!forum/mycli-users
Home: http://mycli.net
Thanks to the contributor - Zhongyang Guan
mysql root@localhost:(none)>
#出现该命令提示符表示登录成功
四、编写SQL语句测试
*************** 当你发现自己的才华撑不起野心时,就请安静下来学习吧!***************