Skip to content

Instantly share code, notes, and snippets.

@jeffreyroberts
Last active December 23, 2015 05:49
Show Gist options
  • Save jeffreyroberts/6590042 to your computer and use it in GitHub Desktop.
Save jeffreyroberts/6590042 to your computer and use it in GitHub Desktop.
MySQL - Calculate total rows of all tables in a database
SELECT SUM(TABLE_ROWS)
FROM INFORMATION_SCHEMA.TABLES
WHERE TABLE_SCHEMA = '<database_name>';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment