We've inherited another linux postgres database project with many
tables. We're trying to get a better understanding of the physical
disk space properties and requirements for this database.
(Nice trick: running "select relname, relfilenode from pg_class where
relname not like 'pg%' order by relfilenode;" helped us determine
which table and index maps to which physical file.)
My questions:
- Is there a SQL command I can run to determine the actual size of a
row within a table? (Or the byte sizes of each individual columns?)
- Is there a listing of the column types and the number of bytes
required?
- Does running vacuum clean up the indexes as well as tables?
- Or is there a different command we should also run for the indexes?
- Or is nothing necessary for the indexes?
Thanks in advance!
Stephane Charette