Jeff Janes <jeff.janes@gmail.com> writes:
>> WHERE nspname NOT IN ('pg_catalog', 'information_schema')
>> AND C.relkind <> 'i'
>> AND nspname !~ '^pg_toast'
> I question the wisdom of that where clause (from the wiki)
> If the pg_catalog relations are big, then they are big and why
> shouldn't they get reported as such?
Agreed, please change it.
(The index and toast exclusions are reasonable, since those will be
accounted for in pg_total_relation_size of the parent. Personally I'd
code the toast exclusion using relkind not a namespace check though.)
regards, tom lane