pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: pg_plan_advice: Don't suppress NO_GATHER advice for parent rels.
2+ messages / 1 participants
[nested] [flat]

* pgsql: pg_plan_advice: Don't suppress NO_GATHER advice for parent rels.
@ 2026-10-09 17:13  Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 2+ messages in thread

From: Robert Haas @ 2026-10-09 17:13 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

pg_plan_advice: Don't suppress NO_GATHER advice for parent rels.

When a table is partitioned, the previous code did not emit NO_GATHER
advice for the parent table, on the theory that doing this for the
child tables was good enough. However, it isn't. I believe what
happened here is that, during development, I was planning to enforce
NO_GATHER by clearing the consider_parallel flag for the children,
which would have been good enough to ensure that parallelism could
not be used at any higher level of the plan tree. Eventually, I
switched course, but failed to realize that this code needed to be
updated as a result. Do that, and add a regression test.

Backpatch-through: 19
Discussion: http://postgr.es/m/CA+TgmoYYHC4i-Gpzc9-JYHqih6pOK+6LTYFiNR-PioXG1nKkOQ@mail.gmail.com

Branch
------
master

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

Modified Files
--------------
contrib/pg_plan_advice/expected/gather.out        | 66 +++++++++++++++++++
contrib/pg_plan_advice/expected/partitionwise.out | 78 ++++++++++++-----------
contrib/pg_plan_advice/pgpa_scan.c                |  7 +-
contrib/pg_plan_advice/sql/gather.sql             | 26 ++++++++
4 files changed, 135 insertions(+), 42 deletions(-)



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

* pgsql: pg_plan_advice: Don't suppress NO_GATHER advice for parent rels.
@ 2026-10-09 17:13  Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 2+ messages in thread

From: Robert Haas @ 2026-10-09 17:13 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

pg_plan_advice: Don't suppress NO_GATHER advice for parent rels.

When a table is partitioned, the previous code did not emit NO_GATHER
advice for the parent table, on the theory that doing this for the
child tables was good enough. However, it isn't. I believe what
happened here is that, during development, I was planning to enforce
NO_GATHER by clearing the consider_parallel flag for the children,
which would have been good enough to ensure that parallelism could
not be used at any higher level of the plan tree. Eventually, I
switched course, but failed to realize that this code needed to be
updated as a result. Do that, and add a regression test.

Backpatch-through: 19
Discussion: http://postgr.es/m/CA+TgmoYYHC4i-Gpzc9-JYHqih6pOK+6LTYFiNR-PioXG1nKkOQ@mail.gmail.com

Branch
------
REL_19_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/13cd2227c0170f2760c4a79821e2c285171dd57f

Modified Files
--------------
contrib/pg_plan_advice/expected/gather.out        | 66 +++++++++++++++++++
contrib/pg_plan_advice/expected/partitionwise.out | 78 ++++++++++++-----------
contrib/pg_plan_advice/pgpa_scan.c                |  7 +-
contrib/pg_plan_advice/sql/gather.sql             | 26 ++++++++
4 files changed, 135 insertions(+), 42 deletions(-)



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


end of thread, other threads:[~2026-10-09 17:13 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2026-10-09 17:13 pgsql: pg_plan_advice: Don't suppress NO_GATHER advice for parent rels. Robert Haas <rhaas@postgresql.org>
2026-10-09 17:13 pgsql: pg_plan_advice: Don't suppress NO_GATHER advice for parent rels. Robert Haas <rhaas@postgresql.org>

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