On Wed, 25 Nov 2026 at 17:23, Nisha Moond <[email protected]> wrote:
>
> Attached v2 patch fixing above as well as other comments from Hou-san at [2].

Thanks for the updated patch, one comment:
With this change, setting conflict_log_destination to log in ALTER
SUBSCRIPTION will fail with an inappropriate hint: "Use DROP ...
CASCADE to drop the dependent objects too". This hint is misleading
because ALTER SUBSCRIPTION does not support CASCADE(it is ok in drop
subscription case):
@@ -1628,7 +1630,8 @@ alter_sub_conflict_log_dest(Subscription *sub,
ConflictLogDest oldlogdest,
                if (!want_table)
                {
                        drop_sub_conflict_log_table(sub->oid, sub->name,
-
         sub->conflictlogrelid);
+
         sub->conflictlogrelid, DROP_RESTRICT,
+
         false);

Ex:
-- Create a view on CLT table
create view v1 as select * from pg_conflict.pg_conflict_log_16392;
-- Alter subscription fails with inappropriate hint "HINT:  Use DROP
... CASCADE to drop the dependent objects too"
postgres=# alter subscription sub1 set (conflict_log_destination = log);
ERROR:  cannot drop table pg_conflict.pg_conflict_log_16392 because
other objects depend on it
DETAIL:  view v1 depends on table pg_conflict.pg_conflict_log_16392
HINT:  Use DROP ... CASCADE to drop the dependent objects too.

Regards,
Vignesh


Reply via email to