Re: vacuumdb changes for stats import/export

Nathan Bossart <nathandbossart@gmail.com>

From: Nathan Bossart <nathandbossart@gmail.com>
To: "David G. Johnston" <david.g.johnston@gmail.com>
Cc: Frédéric Yhuel <frederic.yhuel@dalibo.com>, Corey Huinker <corey.huinker@gmail.com>, Bruce Momjian <bruce@momjian.us>, John Naylor <johncnaylorls@gmail.com>, Masahiko Sawada <sawada.mshk@gmail.com>, Jeff Davis <pgsql@j-davis.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" <alvherre@alvh.no-ip.org>
Date: 2025-07-28T18:46:34Z
Lists: pgsql-hackers
On Mon, Jul 28, 2025 at 09:22:29AM -0700, David G. Johnston wrote:
> On Monday, July 28, 2025, Frédéric Yhuel <frederic.yhuel@dalibo.com> wrote:
>> On 7/28/25 16:47, Nathan Bossart wrote:
>>> Obviously, this wording isn't clear enough.  We might need to either
>>> remove that sentence or add "When used in conjunction with
>>> --analyze-in-stages..."
>>
>> I vote for the second option.
>
> Makes sense. 

It seems like there is some support for adding "When used in conjunction
with --analyze in stages..." to the beginning of the sentence.  I'll give
it another day or two for any further discussion before committing.

-- 
nathan



Commits

  1. doc: Adjust documentation for vacuumdb --missing-stats-only.

  2. Update guidance for running vacuumdb after pg_upgrade.

  3. vacuumdb: Add option for analyzing only relations missing stats.

  4. vacuumdb: Teach vacuum_one_database() to reuse query results.