Skip to content

Instantly share code, notes, and snippets.

@nikitug
Created June 25, 2010 13:33
Show Gist options
  • Save nikitug/452846 to your computer and use it in GitHub Desktop.
Save nikitug/452846 to your computer and use it in GitHub Desktop.
MySQL table size
SELECT
table_name,
engine,
ROUND(data_length/1024/1024,2) AS total_size_mb,
table_rows
FROM
information_schema.tables
WHERE
table_schema=DATABASE();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment