mysql檢視某張表、庫的大小
阿新 • • 發佈:2018-11-15
1、查詢某張表的大小
mysql > select concat(round(sum(DATA_LENGTH/1024/1024),2),'M') from information_schema.tables where table_schema='test' AND table_name='t9';
2、檢視某個資料庫表的資料
[[email protected] ~]# mysqlshow -uroot -p --count test Enter password: Database: test +--------+----------+------------+ | Tables | Columns | Total Rows | +--------+----------+------------+ | t1 | 1 | 2 | | t2 | 1 | 2 | | t3 | 2 | 1 | | t4 | 1 | 6 | | t5 | 1 | 1 | | t6 | 1 | 14 | | t7 | 1 | 0 | | t8 | 1 | 12 | | t9 | 7 | 48147 | +--------+----------+------------+3、查詢某個資料庫某張表的資料 #類似於desc