RE: BUG #18644: ALTER PUBLICATION ... SET (publish_via_partition_root) wrong/undocumented behavior. - Mailing list pgsql-bugs

From Hayato Kuroda (Fujitsu)
Subject RE: BUG #18644: ALTER PUBLICATION ... SET (publish_via_partition_root) wrong/undocumented behavior.
Date
Msg-id TYAPR01MB569256840EA1354B4F8BD9E2F54D2@TYAPR01MB5692.jpnprd01.prod.outlook.com
Whole thread Raw
In response to Re: BUG #18644: ALTER PUBLICATION ... SET (publish_via_partition_root) wrong/undocumented behavior.  (Maxim Boguk <maxim.boguk@gmail.com>)
Responses Re: BUG #18644: ALTER PUBLICATION ... SET (publish_via_partition_root) wrong/undocumented behavior.
List pgsql-bugs
Dear Maxim,

> Problem also happens if publication is created via FOR ALL TABLES /
> FOR TABLES IN SCHEMA (without directly including partition head into
> publication).

Thanks for pointing out. I also confirmed this issue can happen for
FOR ALL TABLES/FOR TABLES IN SCHEMA publications. I modified a documentation.

> What is expected behavior in case when only partitions are included
> into publication/subscription set, but partition head isn't included
> and publish_via_partition_root='true' executed?

Just to confirm - you meant like below definitions, right?

```
create table tab (a int) partition by range (a);
create table tab_1 partition of tab for values from (-10) to (0);
create table tab_2 partition of tab for values from (0) to (10);
create publication pub for table tab_1, tab_2 with (publish_via_partition_root = true);
```

For now, changes are replicated as leaf table's one in above case. And I think
it is the expected behavior because users expressly specifies them.

Best regards,
Hayato Kuroda
FUJITSU LIMITED


pgsql-bugs by date:

Previous
From: Tender Wang
Date:
Subject: Re: BUG #18568: BUG: Result wrong when do group by on partition table!
Next
From: Tender Wang
Date:
Subject: Re: BUG #18568: BUG: Result wrong when do group by on partition table!