From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix executor prune failure when plan already pruned
Date: Thu, 16 Aug 2018 16:01:00 +0000
Message-ID: <E1fqKho-0001JY-WA@gemulon.postgresql.org> (raw)
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@gmx.de>
Author: David Rowley <david.rowley@2ndquadrant.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(-)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: alvherre@alvh.no-ip.org
Subject: Re: pgsql: Fix executor prune failure when plan already pruned
In-Reply-To: <E1fqKho-0001JY-WA@gemulon.postgresql.org>
References: <E1fqKho-0001JY-WA@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
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