Get the App
SLTechnology News&Howtos  ›  Database  › 

Query each table size

Shulou Source: shulou.com Published: 2022-06-01 16:36:55 10月01日 Update

SELECT CONCAT (table_schema,'.',table_name) AS 'Table Name', CONCAT (ROUND (table_rows/1000000,4),' M') AS 'Number of Rows', CONCAT (ROUND (data_length/ (1024 1024), 2),' MB') AS 'Data Size', CONCAT (ROUND (index_length/ (1024 1024), 2),' MB') AS 'Index Size', CONCAT (ROUND ((data_length+index_length) / (1024) 1024 1024), 4) 'G') AS'Total'FROM information_schema.TABLES WHERE table_schema LIKE' yuan' order by Total desc

Tags: Size query Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Information MariaDB Redmi Microsoft Linux