SELECT
table_schema AS 'Database',
CONCAT(ROUND(SUM(data_length + index_length) / 1024 / 1024, 2), 'MB') AS 'Size'
FROM
information_schema.tables
WHERE
table_schema IN (SELECT schema_name FROM information_schema.schemata)
GROUP BY
table_schema;
- THE END -
最后修改:2023年10月30日
非特殊说明,本博所有文章均为博主原创。
如若转载,请注明出处:https://www.95app.top/%e6%9f%a5%e7%9c%8bmysql%e6%89%80%e6%9c%89%e5%ba%93%e7%9a%84%e5%a4%a7%e5%b0%8f/