Created
July 6, 2010 21:50
-
-
Save elecnix/465974 to your computer and use it in GitHub Desktop.
Show largest PostgreSQL tables
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| SELECT | |
| pg_relation_size(c.oid), | |
| pg_size_pretty(pg_relation_size(c.oid)), | |
| relkind, | |
| relname, | |
| nspname | |
| FROM | |
| pg_class c, | |
| pg_namespace n | |
| WHERE | |
| n.oid = c.relnamespace | |
| ORDER BY pg_relation_size(c.oid) DESC; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment