Re: why can't a table be part of the same publication as its schema - Mailing list pgsql-hackers

From Tom Lane
Subject Re: why can't a table be part of the same publication as its schema
Date
Msg-id 37271.1662704091@sss.pgh.pa.us
Whole thread Raw
In response to Re: why can't a table be part of the same publication as its schema  (Amit Kapila <amit.kapila16@gmail.com>)
Responses Re: why can't a table be part of the same publication as its schema
List pgsql-hackers
Amit Kapila <amit.kapila16@gmail.com> writes:
> To avoid these confusions, we have disallowed adding a table if its
> schema is already part of the publication and vice-versa.

Really?

Is there logic in ALTER TABLE SET SCHEMA that rejects the command
dependent on the contents of the publication tables?  If so, are
there locks taken in both ALTER TABLE SET SCHEMA and the
publication-modifying commands that are sufficient to prevent
race conditions in such changes?

This position sounds quite untenable from here, even if I found
your arguments-in-support convincing, which I don't really.
ISTM the rule should be along the lines of "table S.T should
be published either if schema S is published or S.T itself is".
There's no obvious need to interconnect the two conditions.

            regards, tom lane



pgsql-hackers by date:

Previous
From: John Naylor
Date:
Subject: Re: Minimum bison and flex versions
Next
From: Bharath Rupireddy
Date:
Subject: Re: Switching XLog source from archive to streaming when primary available