Re: vacuumdb changes for stats import/export
John Naylor <johncnaylorls@gmail.com>
From: John Naylor <johncnaylorls@gmail.com>
To: Nathan Bossart <nathandbossart@gmail.com>
Cc: Masahiko Sawada <sawada.mshk@gmail.com>, Bruce Momjian <bruce@momjian.us>, Jeff Davis <pgsql@j-davis.com>, Corey Huinker <corey.huinker@gmail.com>, jian he <jian.universality@gmail.com>, Matthias van de Meent <boekewurm+postgres@gmail.com>,
Tom Lane <tgl@sss.pgh.pa.us>, Magnus Hagander <magnus@hagander.net>, Stephen Frost <sfrost@snowman.net>, Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>,
Peter Smith <smithpb2250@gmail.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>,
alvherre@alvh.no-ip.org
Date: 2025-03-10T05:35:22Z
Lists: pgsql-hackers
On Fri, Mar 7, 2025 at 4:47 AM Nathan Bossart <nathandbossart@gmail.com> wrote: > > On Thu, Mar 06, 2025 at 06:30:59PM +0700, John Naylor wrote: > > IIUC correctly, pg_statistic doesn't store stats on itself, so this > > causes the query result to always contain pg_statistic -- does that > > get removed elsewhere? > > Good catch. I think the current behavior is to call ANALYZE on > pg_statistic, too, but that should be mostly harmless (analyze_rel() > refuses to process it). I suppose we could try to avoid returning > pg_statistic from the catalog query, but we don't bother doing that for any > other vacuumdb modes, so I'm tempted to leave it alone. Okay, thanks for confirming. I have no further comments. -- John Naylor Amazon Web Services
Commits
-
doc: Adjust documentation for vacuumdb --missing-stats-only.
- ee924698d566 19 (unreleased) landed
- da103c7bc806 18.0 landed
-
Update guidance for running vacuumdb after pg_upgrade.
- c9d502eb6809 18.0 landed
-
vacuumdb: Add option for analyzing only relations missing stats.
- edba754f052e 18.0 landed
- 5f8eb25706b6 18.0 landed
-
vacuumdb: Teach vacuum_one_database() to reuse query results.
- 9c03c8d18721 18.0 landed