Re: Statistics Import and Export: difference in statistics dumped - Mailing list pgsql-hackers

From Jeff Davis
Subject Re: Statistics Import and Export: difference in statistics dumped
Date
Msg-id 5053263e41692dc2358a642403e9aa6fcda53578.camel@j-davis.com
Whole thread Raw
In response to Re: Statistics Import and Export: difference in statistics dumped  (Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>)
List pgsql-hackers
On Fri, 2025-02-28 at 14:51 +0530, Ashutosh Bapat wrote:
> 2. We aren't restoring the statistics faithfully - as mentioned in
> Greg's reply. If users dump and restore with autovacuum turned off,
> they will be surprised to see the statistics to be different on the
> original and restored database - which may have other effects like
> change in plans.

Then let's just address that concern directly: disable updating stats
implicitly if autovacuum is off. If autovacuum is on, the user
shouldn't have an expectation of stable stats anyway. Patch attached.

Regards,
    Jeff Davis


Attachment

pgsql-hackers by date:

Previous
From: Thom Brown
Date:
Subject: Re: making EXPLAIN extensible
Next
From: Heikki Linnakangas
Date:
Subject: Re: Interrupts vs signals