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语句测试

20200409183236

posted @ 2020-12-27 14:29  吕振江  阅读(233)  评论(0编辑  收藏  举报
浏览器标题切换
浏览器标题切换end