pgsql: Disallow COPY FREEZE on foreign tables.

From: Nathan Bossart <nathan(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Disallow COPY FREEZE on foreign tables.
Date: 2025-02-06 21:24:16
Message-ID: E1tg9M8-005jhh-2X@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Disallow COPY FREEZE on foreign tables.

This didn't actually work: the COPY succeeds, but the FREEZE
optimization isn't applied. There doesn't seem to be an easy way
to support FREEZE on foreign tables, so let's follow the precedent
established by commit 5c9a5513a3 by raising an error early. This
is arguably a bug fix, but due to the lack of reports, the minimal
discussion on the mailing list, and the potential to break existing
scripts, I am not back-patching it for now.

Author: Sami Imseih <samimseih(at)gmail(dot)com>
Reviewed-by: Zhang Mingli <zmlpostgres(at)gmail(dot)com>
Discussion: https://postgr.es/m/CAA5RZ0ujeNgKpE3OrLtR%3DeJGa5LkGMekFzQTwjgw%3DrzaLufQLQ%40mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/401a6956fa69c9202cbc14c09ba8a9c430b90cac

Modified Files
--------------
doc/src/sgml/ref/copy.sgml | 2 +-
src/backend/commands/copyfrom.c | 6 ++++++
src/test/regress/expected/copy.out | 8 ++++++++
src/test/regress/sql/copy.sql | 10 ++++++++++
4 files changed, 25 insertions(+), 1 deletion(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Michael Paquier 2025-02-07 00:45:00 pgsql: Move SQL tests of pg_stat_io for WAL data to recovery test 029_s
Previous Message Daniel Gustafsson 2025-02-06 21:22:01 pgsql: libpq: Handle asynchronous actions during SASL