From: | Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at> |
---|---|
To: | veem v <veema0000(at)gmail(dot)com> |
Cc: | pgsql-general <pgsql-general(at)lists(dot)postgresql(dot)org> |
Subject: | Re: When manual analyze is needed |
Date: | 2024-03-04 08:40:34 |
Message-ID: | fb4332fb1e8c5b0ab11e68d10b2c4c8ebf0f5aa4.camel@cybertec.at |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Mon, 2024-03-04 at 10:16 +0530, veem v wrote:
> So the partitioned table stats is nothing but the rolledover stats of all the partitions.
> As you mentioned, autoanalyze only works for child partitions but not the partition tables,
> so does it mean we have to schedule some jobs manually(through some scheduletr like pg_cron)
> to analyze these partitioned tables at certain time intervals to keep those up to date for
> partitioned tables?
Something like that, yes.
> And won't that scan all the child partitions again to have the stats aggregated/rolled
> over from all the child partitions level to the table level?
Yes.
> Additionally if a query was working fine but suddenly takes a suboptimal plan because
> of missing stats , do we have any hash value column on any performance view associated
> with the queryid which we can refer to see past vs current plans difference and identify
> such issues quickly and fix it?
Not that I know of.
Yours,
Laurenz Albe
From | Date | Subject | |
---|---|---|---|
Next Message | albrecht.dress | 2024-03-04 12:09:47 | Inconsistent results in timestamp/interval comparison |
Previous Message | Michał Kłeczek | 2024-03-04 07:09:26 | Re: postgres_fdw aggregate pushdown for group by with expressions |