Fix double publish of child table's data. We publish the child table's data twice for a publication that has both child and parent tables and is published with publish_via_partition_root as true. This happens because subscribers will initiate synchronization using both parent and child tables, since it gets both as separate tables in the initial table list.
Ensure that pg_publication_tables returns only parent tables in such cases. Author: Hou Zhijie Reviewed-by: Greg Nancarrow, Amit Langote, Vignesh C, Amit Kapila Backpatch-through: 13 Discussion: https://postgr.es/m/os0pr01mb57167f45d481f78cdc5986f794...@os0pr01mb5716.jpnprd01.prod.outlook.com Branch ------ REL_14_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/614b77d65a3859ad8d2c1c28475e98ddee06dc50 Modified Files -------------- src/backend/catalog/pg_publication.c | 52 +++++++++++++++++++++++++++++++ src/test/regress/expected/publication.out | 9 ++++++ src/test/regress/sql/publication.sql | 4 +++ src/test/subscription/t/013_partition.pl | 18 ++++++++--- 4 files changed, 79 insertions(+), 4 deletions(-)