From: | Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
---|---|
To: | pgsql-committers(at)lists(dot)postgresql(dot)org |
Subject: | pgsql: Fix executor prune failure when plan already pruned |
Date: | 2018-08-16 16:01:00 |
Message-ID: | E1fqKho-0001JY-WA@gemulon.postgresql.org |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Fix executor prune failure when plan already pruned
In a multi-layer partitioning setup, if at plan time all the
sub-partitions are pruned but the intermediate one remains, the executor
later throws a spurious error that there's nothing to prune. That is
correct, but there's no reason to throw an error. Therefore, don't.
Reported-by: Andreas Seltenreich <seltenreich(at)gmx(dot)de>
Author: David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>
Discussion: https://postgr.es/m/87in4h98i0.fsf@ansel.ydns.eu
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/1eb9221585c25cad1a563bc3414f697dae3fbc8b
Modified Files
--------------
src/backend/executor/execPartition.c | 9 +++++++--
src/test/regress/expected/partition_prune.out | 18 ++++++++++++++++++
src/test/regress/sql/partition_prune.sql | 12 ++++++++++++
3 files changed, 37 insertions(+), 2 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2018-08-16 17:01:16 | pgsql: Require a C99-compliant snprintf(), and remove related workaroun |
Previous Message | Tomas Vondra | 2018-08-16 14:55:57 | pgsql: Close the file descriptor in ApplyLogicalMappingFile |