agora inbox for pgsql-committers@postgresql.org
help / color / mirror / Atom feedFrom: Amit Kapila <akapila@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Disallow SET UNLOGGED for tables in a publication's EXCEPT claus
Date: Mon, 14 Sep 2026 04:15:40 +0000
Message-ID: <E1x5y6W-00000000EXN-0Cqm@gemulon.postgresql.org> (raw)
Disallow SET UNLOGGED for tables in a publication's EXCEPT clause.
Unlogged tables cannot be replicated, so they can neither be published nor
be named in a publication's EXCEPT clause. ALTER TABLE ... SET UNLOGGED
checked only whether the table was published, so a table in an EXCEPT
clause could still be made unlogged, leaving a state that CREATE
PUBLICATION would reject and that pg_dump could not restore.
Author: Vignesh C <vignesh21@gmail.com>
Reviewed-by: Amit Kapila <amit.kapila16@gmail.com>
Reviewed-by: Chao Li <li.evan.chao@gmail.com>
Reviewed-by: shveta malik <shveta.malik@gmail.com>
Reviewed-by: Hayato Kuroda <kuroda.hayato@fujitsu.com>
Reviewed-by: Peter Smith <smithpb2250@gmail.com>
Reviewed-by: Zhijie Hou <houzj.fnst@fujitsu.com>
Discussion: https://postgr.es/m/CALDaNm1r2MkGu6h8zgU1Kj1sX-FcMQ7wGTeLSnhx-5joiyXEvg@mail.gmail.com
Backpatch-through: 19, where it was introduced
Branch
------
REL_19_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/17d84c2b67f38cc3fc8b868c668297d59a299d97
Modified Files
--------------
src/backend/catalog/pg_publication.c | 19 +++++++++++++++++++
src/backend/commands/tablecmds.c | 13 +++++++------
src/include/catalog/pg_publication.h | 1 +
src/test/regress/expected/publication.out | 10 ++++++++++
src/test/regress/sql/publication.sql | 8 ++++++++
5 files changed, 45 insertions(+), 6 deletions(-)
view thread (2+ messages)
Message-ID: <E1x5y6W-00000000EXN-0Cqm@gemulon.postgresql.org>
Permalink: ../E1x5y6W-00000000EXN-0Cqm@gemulon.postgresql.org/
Also on: postgresql.org/message-id/E1x5y6W-00000000EXN-0Cqm@gemulon.postgresql.org
reply
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 using the --to and --cc options:
reply via email
To: pgsql-committers@postgresql.org
Cc: akapila@postgresql.org, pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Disallow SET UNLOGGED for tables in a publication's EXCEPT claus
In-Reply-To: <E1x5y6W-00000000EXN-0Cqm@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 agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox