Re: Skipping schema changes in publication

From: Nisha Moond <nisha(dot)moond412(at)gmail(dot)com>
To: vignesh C <vignesh21(at)gmail(dot)com>
Cc: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Andrei Lepikhov <lepihov(at)gmail(dot)com>, shveta malik <shveta(dot)malik(at)gmail(dot)com>, Shlok Kyal <shlok(dot)kyal(dot)oss(at)gmail(dot)com>, Ashutosh Sharma <ashu(dot)coek88(at)gmail(dot)com>, "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>, Dilip Kumar <dilipbalaut(at)gmail(dot)com>, Peter Smith <smithpb2250(at)gmail(dot)com>, "Zhijie Hou (Fujitsu)" <houzj(dot)fnst(at)fujitsu(dot)com>, YeXiu <1518981153(at)qq(dot)com>, Ian Lawrence Barwick <barwick(at)gmail(dot)com>, Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Skipping schema changes in publication
Date: 2026-03-09 07:00:42
Message-ID: CABdArM65WySkXh0KSTdpX2cxKEPBdGGTt693vhpgAdW-uH97JQ@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Mar 9, 2026 at 8:22 AM vignesh C <vignesh21(at)gmail(dot)com> wrote:
>
> The attached v59 patch has the changes to update the syntax accordingly.
>
Thanks for the patch, here are few comments:

1) commit message:
"... the user must first modify
the publication using ALTER PUBLICATION ... SET EXCEPT TABLE
before attaching the partition."

The command is modified now and "SET EXCEPT TABLE" is no longer
supported, so it should be -

"... the user must first modify
the publication using ALTER PUBLICATION ... SET ALL TABLES EXCEPT TABLE
before attaching the partition."
~~~

2) Unexpected behavior: "ALTER PUBLICATION pub1 SET ALL TABLES;"
succeeds for a non-ALL TABLES publication and removes the existing
tables from the publication:

CREATE publication pub1 for table t1;

postgres=# \dRp+
Publication pub1
Owner | All tables | All sequences | Inserts | Updates | Deletes |
Truncates | Generated columns | Via root | Description
---------+------------+---------------+---------+---------+---------+-----------+-------------------+----------+-------------
moond_n | f | f | t | t | t |
t | none | f |
Tables:
"public.t1"

postgres=# alter publication pub1 set all tables ;
ALTER PUBLICATION

postgres=# \dRp+
Publication pub1
Owner | All tables | All sequences | Inserts | Updates | Deletes |
Truncates | Generated columns | Via root | Description
---------+------------+---------------+---------+---------+---------+-----------+-------------------+----------+-------------
moond_n | f | f | t | t | t |
t | none | f |
(1 row)

3) Should we add a test for "ALTER PUBLICATION tab_pub SET ALL
TABLES;" verification?

--
Thanks,
Nisha

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2026-03-09 07:34:45 Re: Skipping schema changes in publication
Previous Message Xuneng Zhou 2026-03-09 06:59:31 Re: Refactor recovery conflict signaling a little