pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: pg_dump: Include column statistics for index-backed constraints 7+ messages / 1 participants [nested] [flat]
* pgsql: pg_dump: Include column statistics for index-backed constraints @ 2026-10-02 08:03 Michael Paquier <michael@paquier.xyz> 0 siblings, 0 replies; 7+ messages in thread From: Michael Paquier @ 2026-10-02 08:03 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org pg_dump: Include column statistics for index-backed constraints dumpIndex() emits ALTER INDEX .. SET STATISTICS for per-column statistics targets, but dumpConstraint() never did. Targets set on the expression columns of an exclusion constraint's index were silently lost on dump/restore and pg_upgrade. The same code can be used in the index and constraint dump code to generate these ALTER INDEX commands. The logic has been refactored so that both share a new subroutine in charge of generating all these custom SET STATISTICS, if any. Oversight in e4fca461ab6f. Author: Zsolt Parragi <zsolt.parragi@percona.com> Reviewed-by: Chao Li <li.evan.chao@gmail.com> Reviewed-by: Andrew Krylosov <krylosov.andrew@gmail.com> Discussion: https://postgr.es/m/CAN4CZFMd9riOuV5LkM+uV=uF-HYp49C8Fh22xWyMxptGLBCZ3A@mail.gmail.com Backpatch-through: 14 Branch ------ REL_14_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/a96a9e17064ba0e5ba08514c4055200edab2b29d Modified Files -------------- src/bin/pg_dump/pg_dump.c | 88 +++++++++++++++++++++------------------- src/bin/pg_dump/t/002_pg_dump.pl | 25 ++++++++++++ 2 files changed, 72 insertions(+), 41 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: pg_dump: Include column statistics for index-backed constraints @ 2026-10-02 08:03 Michael Paquier <michael@paquier.xyz> 0 siblings, 0 replies; 7+ messages in thread From: Michael Paquier @ 2026-10-02 08:03 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org pg_dump: Include column statistics for index-backed constraints dumpIndex() emits ALTER INDEX .. SET STATISTICS for per-column statistics targets, but dumpConstraint() never did. Targets set on the expression columns of an exclusion constraint's index were silently lost on dump/restore and pg_upgrade. The same code can be used in the index and constraint dump code to generate these ALTER INDEX commands. The logic has been refactored so that both share a new subroutine in charge of generating all these custom SET STATISTICS, if any. Oversight in e4fca461ab6f. Author: Zsolt Parragi <zsolt.parragi@percona.com> Reviewed-by: Chao Li <li.evan.chao@gmail.com> Reviewed-by: Andrew Krylosov <krylosov.andrew@gmail.com> Discussion: https://postgr.es/m/CAN4CZFMd9riOuV5LkM+uV=uF-HYp49C8Fh22xWyMxptGLBCZ3A@mail.gmail.com Backpatch-through: 14 Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/80931d131a95ddcddc7b671d4fee7aceeb12a314 Modified Files -------------- src/bin/pg_dump/pg_dump.c | 86 ++++++++++++++++++++++------------------ src/bin/pg_dump/t/002_pg_dump.pl | 25 ++++++++++++ 2 files changed, 72 insertions(+), 39 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: pg_dump: Include column statistics for index-backed constraints @ 2026-10-02 08:03 Michael Paquier <michael@paquier.xyz> 0 siblings, 0 replies; 7+ messages in thread From: Michael Paquier @ 2026-10-02 08:03 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org pg_dump: Include column statistics for index-backed constraints dumpIndex() emits ALTER INDEX .. SET STATISTICS for per-column statistics targets, but dumpConstraint() never did. Targets set on the expression columns of an exclusion constraint's index were silently lost on dump/restore and pg_upgrade. The same code can be used in the index and constraint dump code to generate these ALTER INDEX commands. The logic has been refactored so that both share a new subroutine in charge of generating all these custom SET STATISTICS, if any. Oversight in e4fca461ab6f. Author: Zsolt Parragi <zsolt.parragi@percona.com> Reviewed-by: Chao Li <li.evan.chao@gmail.com> Reviewed-by: Andrew Krylosov <krylosov.andrew@gmail.com> Discussion: https://postgr.es/m/CAN4CZFMd9riOuV5LkM+uV=uF-HYp49C8Fh22xWyMxptGLBCZ3A@mail.gmail.com Backpatch-through: 14 Branch ------ REL_19_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/fa96254c63005dd8d57f5e7af6eb8eac1b9e19e1 Modified Files -------------- src/bin/pg_dump/pg_dump.c | 86 ++++++++++++++++++++++------------------ src/bin/pg_dump/t/002_pg_dump.pl | 25 ++++++++++++ 2 files changed, 72 insertions(+), 39 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: pg_dump: Include column statistics for index-backed constraints @ 2026-10-02 08:03 Michael Paquier <michael@paquier.xyz> 0 siblings, 0 replies; 7+ messages in thread From: Michael Paquier @ 2026-10-02 08:03 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org pg_dump: Include column statistics for index-backed constraints dumpIndex() emits ALTER INDEX .. SET STATISTICS for per-column statistics targets, but dumpConstraint() never did. Targets set on the expression columns of an exclusion constraint's index were silently lost on dump/restore and pg_upgrade. The same code can be used in the index and constraint dump code to generate these ALTER INDEX commands. The logic has been refactored so that both share a new subroutine in charge of generating all these custom SET STATISTICS, if any. Oversight in e4fca461ab6f. Author: Zsolt Parragi <zsolt.parragi@percona.com> Reviewed-by: Chao Li <li.evan.chao@gmail.com> Reviewed-by: Andrew Krylosov <krylosov.andrew@gmail.com> Discussion: https://postgr.es/m/CAN4CZFMd9riOuV5LkM+uV=uF-HYp49C8Fh22xWyMxptGLBCZ3A@mail.gmail.com Backpatch-through: 14 Branch ------ REL_18_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/37bbf5bba09c4244d74f152557e69f73f2b6690e Modified Files -------------- src/bin/pg_dump/pg_dump.c | 86 ++++++++++++++++++++++------------------ src/bin/pg_dump/t/002_pg_dump.pl | 25 ++++++++++++ 2 files changed, 72 insertions(+), 39 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: pg_dump: Include column statistics for index-backed constraints @ 2026-10-02 08:03 Michael Paquier <michael@paquier.xyz> 0 siblings, 0 replies; 7+ messages in thread From: Michael Paquier @ 2026-10-02 08:03 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org pg_dump: Include column statistics for index-backed constraints dumpIndex() emits ALTER INDEX .. SET STATISTICS for per-column statistics targets, but dumpConstraint() never did. Targets set on the expression columns of an exclusion constraint's index were silently lost on dump/restore and pg_upgrade. The same code can be used in the index and constraint dump code to generate these ALTER INDEX commands. The logic has been refactored so that both share a new subroutine in charge of generating all these custom SET STATISTICS, if any. Oversight in e4fca461ab6f. Author: Zsolt Parragi <zsolt.parragi@percona.com> Reviewed-by: Chao Li <li.evan.chao@gmail.com> Reviewed-by: Andrew Krylosov <krylosov.andrew@gmail.com> Discussion: https://postgr.es/m/CAN4CZFMd9riOuV5LkM+uV=uF-HYp49C8Fh22xWyMxptGLBCZ3A@mail.gmail.com Backpatch-through: 14 Branch ------ REL_17_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/5e158a2e43c2e7fcc1e579f81c2f3645285cba40 Modified Files -------------- src/bin/pg_dump/pg_dump.c | 86 ++++++++++++++++++++++------------------ src/bin/pg_dump/t/002_pg_dump.pl | 25 ++++++++++++ 2 files changed, 72 insertions(+), 39 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: pg_dump: Include column statistics for index-backed constraints @ 2026-10-02 08:03 Michael Paquier <michael@paquier.xyz> 0 siblings, 0 replies; 7+ messages in thread From: Michael Paquier @ 2026-10-02 08:03 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org pg_dump: Include column statistics for index-backed constraints dumpIndex() emits ALTER INDEX .. SET STATISTICS for per-column statistics targets, but dumpConstraint() never did. Targets set on the expression columns of an exclusion constraint's index were silently lost on dump/restore and pg_upgrade. The same code can be used in the index and constraint dump code to generate these ALTER INDEX commands. The logic has been refactored so that both share a new subroutine in charge of generating all these custom SET STATISTICS, if any. Oversight in e4fca461ab6f. Author: Zsolt Parragi <zsolt.parragi@percona.com> Reviewed-by: Chao Li <li.evan.chao@gmail.com> Reviewed-by: Andrew Krylosov <krylosov.andrew@gmail.com> Discussion: https://postgr.es/m/CAN4CZFMd9riOuV5LkM+uV=uF-HYp49C8Fh22xWyMxptGLBCZ3A@mail.gmail.com Backpatch-through: 14 Branch ------ REL_16_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/cb157339c474333ef0e40b3c524a486274cf719e Modified Files -------------- src/bin/pg_dump/pg_dump.c | 86 ++++++++++++++++++++++------------------ src/bin/pg_dump/t/002_pg_dump.pl | 25 ++++++++++++ 2 files changed, 72 insertions(+), 39 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: pg_dump: Include column statistics for index-backed constraints @ 2026-10-02 08:03 Michael Paquier <michael@paquier.xyz> 0 siblings, 0 replies; 7+ messages in thread From: Michael Paquier @ 2026-10-02 08:03 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org pg_dump: Include column statistics for index-backed constraints dumpIndex() emits ALTER INDEX .. SET STATISTICS for per-column statistics targets, but dumpConstraint() never did. Targets set on the expression columns of an exclusion constraint's index were silently lost on dump/restore and pg_upgrade. The same code can be used in the index and constraint dump code to generate these ALTER INDEX commands. The logic has been refactored so that both share a new subroutine in charge of generating all these custom SET STATISTICS, if any. Oversight in e4fca461ab6f. Author: Zsolt Parragi <zsolt.parragi@percona.com> Reviewed-by: Chao Li <li.evan.chao@gmail.com> Reviewed-by: Andrew Krylosov <krylosov.andrew@gmail.com> Discussion: https://postgr.es/m/CAN4CZFMd9riOuV5LkM+uV=uF-HYp49C8Fh22xWyMxptGLBCZ3A@mail.gmail.com Backpatch-through: 14 Branch ------ REL_15_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/3693e2bc00396d55581d9c40c7bd6d768f61d9d3 Modified Files -------------- src/bin/pg_dump/pg_dump.c | 88 +++++++++++++++++++++------------------- src/bin/pg_dump/t/002_pg_dump.pl | 25 ++++++++++++ 2 files changed, 72 insertions(+), 41 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
end of thread, other threads:[~2026-10-02 08:03 UTC | newest] Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2026-10-02 08:03 pgsql: pg_dump: Include column statistics for index-backed constraints Michael Paquier <michael@paquier.xyz> 2026-10-02 08:03 pgsql: pg_dump: Include column statistics for index-backed constraints Michael Paquier <michael@paquier.xyz> 2026-10-02 08:03 pgsql: pg_dump: Include column statistics for index-backed constraints Michael Paquier <michael@paquier.xyz> 2026-10-02 08:03 pgsql: pg_dump: Include column statistics for index-backed constraints Michael Paquier <michael@paquier.xyz> 2026-10-02 08:03 pgsql: pg_dump: Include column statistics for index-backed constraints Michael Paquier <michael@paquier.xyz> 2026-10-02 08:03 pgsql: pg_dump: Include column statistics for index-backed constraints Michael Paquier <michael@paquier.xyz> 2026-10-02 08:03 pgsql: pg_dump: Include column statistics for index-backed constraints Michael Paquier <michael@paquier.xyz>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox