Mysql[命令用法] mysqlshow

mysqlshow用法

最近学习mysql时,有用到mysqlshow,并且遇到一些问题,所以做个记录

mysqlshow命令用于显示mysql服务器中数据库、表和列表信息。

语法

mysqlshow(选项)(参数)

命令解析

-h:MySQL服务器的ip地址或主机名;
-u:连接MySQL服务器的用户名;
-p:连接MySQL服务器的密码;
–count:显示每个数据表中数据的行数;
-k:显示数据表的索引;
-t:显示数据表的类型;
-i:显示数据表的额外信息。

参数

数据库信息:指定要显示的数据库信息,可以是一个数据库名,或者是数据库名和表名,或者是数据库名、表名和列名。


Below,it is a example.First, we use the statement.

mysqlshow

You can get the result below.

这里写图片描述

From the picture,we can learn that if we just use mysqlshow,the shell can’t compile . Why don’t it work ?

It is because the statement need factors , and we use the new mysqlshow -u root -p

Note: I don’t use the factor ‘-h’, just because my MySQL is installed in my computer. If your MySQL is installed in the other machine, you must use ‘-h’.

这里写图片描述

OKay , now it is work . Beside databases , the mysqlshow can seek tables , and the infornation of the table .

这里写图片描述

这里写图片描述

By the way , mysqlshow is used in shell , and not MySQL Command Line Client .

Okay , that is all .

Lucky !

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值