From: | Corey Huinker <corey(dot)huinker(at)gmail(dot)com> |
---|---|
To: | Magnus Hagander <magnus(at)hagander(dot)net> |
Cc: | Jeff Davis <pgsql(at)j-davis(dot)com>, Stephen Frost <sfrost(at)snowman(dot)net>, Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com>, Matthias van de Meent <boekewurm+postgres(at)gmail(dot)com>, Peter Smith <smithpb2250(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com> |
Subject: | Re: Statistics Import and Export |
Date: | 2024-03-31 11:17:26 |
Message-ID: | CADkLM=dTY5bkMB4WO0aTYEOP=re0_QjWfYyPd-A5-BvEQdn9cA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
>
> That will make it *really* hard for any form of automation or drivers of
> this. The information needs to go somewhere where such tools can easily
> consume it, and an informational message during runtime (which is also
> likely to be translated in many environments) is the exact opposite of that.
>
Having given this some thought, I'd be inclined to create a view,
pg_stats_missing, with the same security barrier as pg_stats, but looking
for tables that lack stats on at least one column, or lack stats on an
extended statistics object.
Table structure would be
schemaname name
tablename name
attnames text[]
ext_stats text[]
The informational message, if it changes at all, could reference this new
view as the place to learn about how well the stats import went.
vacuumdb might get a --missing-only option in addition to
--analyze-in-stages.
For that matter, we could add --analyze-missing options to pg_restore and
pg_upgrade to do the mopping up themselves.
From | Date | Subject | |
---|---|---|---|
Next Message | Joe Conway | 2024-03-31 12:15:59 | Re: Security lessons from liblzma |
Previous Message | Justin Pryzby | 2024-03-31 11:11:02 | Re: ALTER TABLE SET ACCESS METHOD on partitioned tables |