From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Disallow MERGE cleanly for foreign partitions
Date: Sat, 15 Oct 2022 18:23:27 +0000
Message-ID: <E1ojlol-002W1r-9e@gemulon.postgresql.org> (raw)
Disallow MERGE cleanly for foreign partitions
While directly targetting a foreign table with MERGE was already
expressly forbidden, we failed to catch the case of a partitioned table
that has a foreign table as a partition; and the result if you try is an
incomprehensible error. Fix that by adding a specific check.
Backpatch to 15.
Reported-by: Tatsuhiro Nakamori <bt22nakamorit@oss.nttdata.com>
Discussion: https://postgr.es/m/bt22nakamorit@oss.nttdata.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/cba4e78f3599f7edc3fb53d1b094f037fbb8158a
Modified Files
--------------
contrib/postgres_fdw/expected/postgres_fdw.out | 5 +++++
contrib/postgres_fdw/sql/postgres_fdw.sql | 4 ++++
src/backend/optimizer/plan/createplan.c | 20 ++++++++++++++++++++
3 files changed, 29 insertions(+)
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: Disallow MERGE cleanly for foreign partitions
In-Reply-To: <E1ojlol-002W1r-9e@gemulon.postgresql.org>
References: <E1ojlol-002W1r-9e@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