| From: | vignesh C <vignesh21(at)gmail(dot)com> |
|---|---|
| To: | shveta malik <shveta(dot)malik(at)gmail(dot)com> |
| Cc: | Nisha Moond <nisha(dot)moond412(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Zsolt Parragi <zsolt(dot)parragi(at)percona(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org, Peter Smith <smithpb2250(at)gmail(dot)com> |
| Subject: | Re: Support EXCEPT for TABLES IN SCHEMA publications |
| Date: | 2026-08-17 07:06:26 |
| Message-ID: | CALDaNm0Qqf=aXob9ObG456qkW8HM8dLEK9JwKyLsUchmT9FsVw@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Mon, 17 Aug 2026 at 09:32, shveta malik <shveta(dot)malik(at)gmail(dot)com> wrote:
>
> These are very simple scenarios which I tested multiple times. These
> scenarios produced an error in the previous version; see:
Sorry for mentioning the wrong test. There is only one issue, here are
the steps for the same with v25 version:
create schema pub_test;
create table pub_test.testpub_tbl_s1(c1 int);
CREATE PUBLICATION testpub_xwire FOR TABLES IN SCHEMA pub_test EXCEPT
(TABLE pub_test.testpub_tbl_s1);
-- publication ends up empty
ALTER PUBLICATION testpub_xwire SET TABLE pub_test.testpub_tbl_s1;
postgres=# \dRp+ testpub_xwire
Publication testpub_xwire
Owner | All tables | All sequences | Inserts | Updates |
Deletes | Truncates | Generated columns | Via root | Description
----------------+------------+---------------+---------+---------+---------+-----------+-------------------+----------+-------------
vigneshwaran_c | f | f | t | t | t
| t | none | f |
(1 row)
postgres=# select * from pg_publication_rel ;
oid | prpubid | prrelid | prexcept | prqual | prattrs
-----+---------+---------+----------+--------+---------
(0 rows)
This has been fixed in the v27 version:
-- Includes the publication table pub_test.testpub_tbl_s1 correctly:
postgres=# \dRp+ testpub_xwire
Publication testpub_xwire
Owner | All tables | All sequences | Inserts | Updates |
Deletes | Truncates | Generated columns | Via root | Description
----------------+------------+---------------+---------+---------+---------+-----------+-------------------+----------+-------------
test | f | f | t | t | t | t
| none | f |
Tables:
"pub_test.testpub_tbl_s1"
postgres=# select * from pg_publication_rel ;
oid | prpubid | prrelid | prexcept | prqual | prattrs
-------+---------+---------+----------+--------+---------
16391 | 16388 | 16385 | f | |
(1 row)
Regards,
Vignesh
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Michael Paquier | 2026-08-17 07:19:44 | Re: Increase repalloc_array() usage in buffile.c |
| Previous Message | Nikhil Sontakke | 2026-08-17 07:03:24 | Dropping a composite attribute causes data integrity violations |