select * from information_schema.TABLES
where information_schema.TABLES.TABLE_SCHEMA='business_shop2'
and information_schema.TABLES.TABLE_NAME='ls_prod'
select CONCAT(ROUND(SUM(t.index_length)/(1024*1024), 2), ' MB') AS 'Total Index Size' from (
select index_length from information_schema.TABLES
where information_schema.TABLES.TABLE_SCHEMA='business_shop2'
and information_schema.TABLES.TABLE_NAME='ls_prod' ) as t
查看数据大小
select CONCAT(ROUND(SUM(t.data_length)/(1024*1024), 2), ' MB') AS 'Total data Size' from (
select data_length from information_schema.TABLES
where information_schema.TABLES.TABLE_SCHEMA='business_shop2'
and information_schema.TABLES.TABLE_NAME='ls_prod' ) as t