Re: Table size does not include toast size - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Table size does not include toast size
Date
Msg-id 15195.1261409493@sss.pgh.pa.us
Whole thread Raw
In response to Re: Table size does not include toast size  (Rafael Martinez <r.m.guerrero@usit.uio.no>)
Responses Re: Table size does not include toast size
List pgsql-hackers
Rafael Martinez <r.m.guerrero@usit.uio.no> writes:
> I am probably missing the point here, why is it not supposed to show the
> size of the table(data) *without* indexes?

Because pg_relation_size is defined at the "physical" level of showing
one relation, where relation means a pg_class entry.  If you want
agglomerations of multiple relations, you can use
pg_total_relation_size, or build your own total if you have some other
usage in mind.  The one you propose seems fairly arbitrary --- for
example, if it includes the toast relation, why not the toast relation's
index too?  It's not like either one is optional from the user's
standpoint.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: Small Bug in GetConflictingVirtualXIDs
Next
From: Rafael Martinez
Date:
Subject: Re: Table size does not include toast size