agora inbox for pgsql-committers@postgresql.org  
help / color / mirror / Atom feed
pgsql: pg_dump: Fix performance regression in attribute statistics quer
2+ messages / 1 participants
[nested] [flat]

* pgsql: pg_dump: Fix performance regression in attribute statistics quer
@ 2026-09-01 21:28  Nathan Bossart <nathan@postgresql.org>
  0 siblings, 0 replies; 2+ messages in thread

From: Nathan Bossart @ 2026-09-01 21:28 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

pg_dump: Fix performance regression in attribute statistics query.

After adding pg_stats.tableid, we taught pg_dump to use it in the
attribute statistics query for servers running v19 or later.
Notably, we did not give this new form of the query a "redundant
filter clause" like we did the pre-v19 form.  Testing indicates
that produces a significant performance regression, and that adding
a similar filter clause to the v19-or-later form of the query fixes
it.

Oversight in commit 4b5ba0c4ca.

Reviewed-by: Sami Imseih <samimseih@gmail.com>
Reviewed-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/apQ9nvLW_zFdarYd%40nathan
Backpatch-through: 19

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/a0edc1c318f3393474d50249ad2355e00fc4cd28

Modified Files
--------------
src/bin/pg_dump/pg_dump.c | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)



^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* pgsql: pg_dump: Fix performance regression in attribute statistics quer
@ 2026-09-01 21:28  Nathan Bossart <nathan@postgresql.org>
  0 siblings, 0 replies; 2+ messages in thread

From: Nathan Bossart @ 2026-09-01 21:28 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

pg_dump: Fix performance regression in attribute statistics query.

After adding pg_stats.tableid, we taught pg_dump to use it in the
attribute statistics query for servers running v19 or later.
Notably, we did not give this new form of the query a "redundant
filter clause" like we did the pre-v19 form.  Testing indicates
that produces a significant performance regression, and that adding
a similar filter clause to the v19-or-later form of the query fixes
it.

Oversight in commit 4b5ba0c4ca.

Reviewed-by: Sami Imseih <samimseih@gmail.com>
Reviewed-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/apQ9nvLW_zFdarYd%40nathan
Backpatch-through: 19

Branch
------
REL_19_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/7da24355a2993721bf9bc54224b3bb3e601530ce

Modified Files
--------------
src/bin/pg_dump/pg_dump.c | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2026-09-01 21:28 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2026-09-01 21:28 pgsql: pg_dump: Fix performance regression in attribute statistics quer Nathan Bossart <nathan@postgresql.org>
2026-09-01 21:28 pgsql: pg_dump: Fix performance regression in attribute statistics quer Nathan Bossart <nathan@postgresql.org>

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox