Skip to content

Instantly share code, notes, and snippets.

@twfahey1
Created July 16, 2020 14:41
Show Gist options
  • Save twfahey1/1feba46ea46741a270de4709ab2155fd to your computer and use it in GitHub Desktop.
Save twfahey1/1feba46ea46741a270de4709ab2155fd to your computer and use it in GitHub Desktop.
Show tables with engine and size - MySQL
SELECT table_name AS "Tables", engine AS "Engine",
-> round(((data_length + index_length) / 1024 / 1024), 2) "Size in MB"
-> FROM information_schema.TABLES
-> WHERE table_schema = "pantheon"
-> ORDER BY (data_length + index_length) DESC;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment