Re: [DOCS] The number of bytes is stored in index_size of pgstatindex() ? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [DOCS] The number of bytes is stored in index_size of pgstatindex() ?
Date
Msg-id 377.1455818470@sss.pgh.pa.us
Whole thread Raw
In response to Re: [DOCS] The number of bytes is stored in index_size of pgstatindex() ?  (Peter Geoghegan <pg@heroku.com>)
Responses Re: [DOCS] The number of bytes is stored in index_size of pgstatindex() ?  (Peter Geoghegan <pg@heroku.com>)
List pgsql-hackers
Peter Geoghegan <pg@heroku.com> writes:
> On Thu, Feb 18, 2016 at 9:40 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> I think this is a bug and we ought to fix the code to include the
>> metapage in the reported index_size.  Thoughts?

> I tend to agree, but I think you should note that specifically in the
> documentation. I'm in favor of tools like pgstattuple and pageinspect
> going into this kind of detail in their documentation generally.

Yeah ... the numbers already appear not to add up because the root page
is counted in index_size but not any other column, so there's already
something worthy of explanation there.  Maybe something like "The reported
index_size will normally correspond to two more pages than are accounted
for by internal_pages + leaf_pages + empty_pages + deleted_pages, because
it also includes the index's metapage and root page".

            regards, tom lane


pgsql-hackers by date:

Previous
From: Peter Geoghegan
Date:
Subject: Re: [DOCS] The number of bytes is stored in index_size of pgstatindex() ?
Next
From: Peter Geoghegan
Date:
Subject: Re: [DOCS] The number of bytes is stored in index_size of pgstatindex() ?