Re: postgres index usage count too high

From: Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>
To: Ayub M <hiayub(at)gmail(dot)com>, PostgreSQL General <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: postgres index usage count too high
Date: 2021-04-29 06:41:51
Message-ID: c31f7c19a5ec70f3a5af5db9b3323450d0bee913.camel@cybertec.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, 2021-04-28 at 18:41 -0400, Ayub M wrote:
> There is a table in the db, whose index_scan count from pg_stat_all_tables for this
> table seems to be too high, there are not that many queries being executed against
> this table. Wondering how this count can be too high.

The table contains cumulative statistics. So you should remember the value, look
again in a day or a week and calculate the difference to see how often index scans
have been used in that time.

Yours,
Laurenz Albe
--
Cybertec | https://www.cybertec-postgresql.com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message DAVID Nicolas 2021-04-29 08:35:19 RE: Open source licenses
Previous Message Ayub M 2021-04-28 22:41:24 postgres index usage count too high