Re: How reliable are the stats collector stats? - Mailing list pgsql-general

From Tom Lane
Subject Re: How reliable are the stats collector stats?
Date
Msg-id 15504.1079157063@sss.pgh.pa.us
Whole thread Raw
In response to How reliable are the stats collector stats?  (Eric Ridge <ebr@tcdi.com>)
Responses Re: How reliable are the stats collector stats?
Re: How reliable are the stats collector stats?
List pgsql-general
Eric Ridge <ebr@tcdi.com> writes:
> Could pg_stats_user_indexes be lying?

Jan probably knows this stuff better than I, but my guess is that if the
counter type you are looking at is incrementing at all, then it's not
too far off.  I certainly can't think of a failure mechanism that would
cause some indexes to be shown with zero hits when other indexes do
get hits.

> I realize the real question is "why aren't these indexes being used",

Up to a point.  If it's a unique index then you may want the
uniqueness-check functionality even if the index is never used for
searches.  (I think that pg_stats only counts search probes, not
accesses made in connection with insertions, but I'm too tired to
go double-check this.)

            regards, tom lane

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: postgres FROM clause problem
Next
From: Eric B.Ridge
Date:
Subject: Re: How reliable are the stats collector stats?