//先进去MySQL自带管理库:information_schema
//自己的数据库:dbwww58com_kuchecarlib
//自己的表:t_carmodelparamvalue mysql> use information_schema;
Database changed
mysql> select data_length,index_length
-> from tables where
-> table_schema='dbwww58com_kuchecarlib'
-> and table_name = 't_carmodelparamvalue';
+-------------+--------------+
| data_length | index_length |
+-------------+--------------+
| 166379520 | 235782144 |
+-------------+--------------+
1 row in set (0.02 sec) mysql> select concat(round(sum(data_length/1024/1024),2),'MB') as data_length_MB,
-> concat(round(sum(index_length/1024/1024),2),'MB') as index_length_MB
-> from tables where
-> table_schema='dbwww58com_kuchecarlib'
-> and table_name = 't_carmodelparamvalue';
+----------------+-----------------+
| data_length_MB | index_length_MB |
+----------------+-----------------+
| 158.67MB | 224.86MB |
+----------------+-----------------+
1 row in set (0.03 sec)

转载:http://blog.csdn.net/partner4java/article/details/7579818

查看mysql表大小的更多相关文章

  1. mysql工具——使用mysqlshow查看mysql对象信息,查看mysql表大小

    关键词:查看表大小,mysqlshow mysqlshow --count -uroot -p test

  2. 查看mysql 表大小

    select round(sum(DATA_LENGTH / 1024 / 1024 ), 2) from `information_schema`.`tables` where table_sche ...

  3. SQL命令查看Mysql数据库大小

    SQL命令查看Mysql数据库大小的方法. 要想知道每个数据库的大小的话,步骤如下:1.进入information_schema 数据库(存放了其他的数据库的信息)use information_sc ...

  4. 查看MySQL数据库大小

    查看MySQL数据库大小 1.首先进入information_schema 数据库(存放了其他的数据库的信息) ? 1 2 mysql> use information_schema; Data ...

  5. 查看mysql表结构和表创建语句的方法(转)

    查看mysql表结构的方法有三种:1.desc tablename;例如:要查看jos_modules表结构的命令:desc jos_modules;查看结果:mysql> desc jos_m ...

  6. 【转】查看mysql表结构和表创建语句的方法

    转自:http://blog.csdn.net/business122/article/details/7531291 查看mysql表结构的方法有三种: 1.desc tablename; 例如: ...

  7. sql查看所有表大小的方法

    sql查看所有表大小的方法. 代码: declare @id int ) declare @pages int declare @dbname sysname ,) ,) ,) create tabl ...

  8. 查看mysql表和数据库的大小

    转自:http://xiaosu.blog.51cto.com/2914416/687835 1.查看数据库的大小 use 数据库名SELECT sum(DATA_LENGTH)+sum(INDEX_ ...

  9. 用SQL命令查看Mysql数据库大小

    要想知道每个数据库的大小的话,步骤如下: 1.进入information_schema 数据库(存放了其他的数据库的信息) use information_schema; 2.查询所有数据的大小: s ...

随机推荐

  1. Cogs 6. 线型网络

    6. 线型网络 ★★☆   输入文件:linec.in   输出文件:linec.out   简单对比时间限制:1 s   内存限制:256 MB [问题描述] 有 N(N<=20)台 PC 放 ...

  2. 位运算 之(1) 按位与(AND)& 操作

    文章作者:ktyanny 由于位运算直接对内存数据进行操作,不需要转成十进制,因此处理速度非常快. 按位与(Bitwise AND),运算符号为& a&b 的操作的结果:a.b中对应位 ...

  3. 关于特殊目录如com null无法删除的处理办法

    1.把以下批处理做成一个del.bat放在桌面 del /f /a /q \\?\%1 rd /s /q \\?\%1 2.需要删除的文件或者文件夹拉到这个文件上就可以了 可以删除没有属性项目中没有安 ...

  4. Git练习1

  5. $each 遍历json字符串

    $.each遍历json对象   查看一个简单的jQuery的例子来遍历一个JavaScript数组对象. var json = [ {"id":"1",&qu ...

  6. PHPExcel探索之旅---阶段二 设置表格样式

    1.设置表格的默认样式为水平居中.垂直居中 getDefaultStyle()函数用来设置默认样式 由活动sheet对象来调用,setVertical()函数和setHorizontal()函数分别用 ...

  7. Uva1149

    每个bin最多只能放两个,所以最佳的贪心策略是从大的开始放,如果有空间放第二个,尽量放最大的. #include <bits/stdc++.h> using namespace std; ...

  8. vue——踩坑

    打包的时候,要记得改一下这个配置路径~ 教程:https://www.cnblogs.com/wanf/p/7871787.html

  9. adb 调系统时间

    1.修改前提 获取系统root权限,然后adb shell进入shell界面 adb shell su 2.时区设置 cat /data/property/persist.sys.timezone / ...

  10. 整理一下postgresql的扩展功能postgis和pgrouting的使用

    postgis windows的下的安装使用postgresql的bin目录下的stackbuiler Ubuntu14.04下的安装: apt-get install postgresql-9.3- ...