Re: Optional skipping of unchanged relations during ANALYZE?

From: David Rowley <dgrowleyml(at)gmail(dot)com>
To: VASUKI M <vasukianand0119(at)gmail(dot)com>
Cc: Christoph Berg <myon(at)debian(dot)org>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Optional skipping of unchanged relations during ANALYZE?
Date: 2026-01-21 06:36:03
Message-ID: CAApHDvqULEFpcaaRBnQt-bsCa5-+mAzDPgK3Qd6C_KXVEAFgBw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, 21 Jan 2026 at 00:02, VASUKI M <vasukianand0119(at)gmail(dot)com> wrote:
> On Tue, Jan 20, 2026 at 4:16 PM Christoph Berg <myon(at)debian(dot)org> wrote:
>> Make sure that doesn't skip tables that were never analyzed before.
>
> Yes, the intention is that SMART ANALYZE would not skip relations that have never been analyzed before.
> The skip decision is based on pg_stat entries, so relations without existing statistics will still be analyzed normally.

If doing this, you would also need to make special consideration for
partitioned tables, as n_mod_since_analyze won't change for those
directly, but it might have changed for their partitions.

David

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message John Naylor 2026-01-21 06:40:11 Re: tuple radix sort
Previous Message lakshmi 2026-01-21 06:32:58 Re: Proposal: Adding compression of temporary files