1SELECT nspname || '.' || relname AS "relation",
2 pg_size_pretty(pg_relation_size(C.oid)) AS "size"
3 FROM pg_class C
4 LEFT JOIN pg_namespace N ON (N.oid = C.relnamespace)
5 WHERE nspname NOT IN ('pg_catalog', 'information_schema')
6 ORDER BY pg_relation_size(C.oid) DESC
7 LIMIT 20;