From 80945212ae967f54763782065cfb6b040b83dc80 Mon Sep 17 00:00:00 2001 From: Colm Date: Fri, 26 Sep 2025 13:19:47 +0100 Subject: [PATCH] PG18 regress sanity: update pg18 ruleutils with fix #7675 (#8216) Fix deparsing of UPDATE statements with indirection (#7675) involved changing ruleutils of our supported Postgres versions. It means that when integrating a new Postgres version we need to update its ruleutils with the relevant parts of #7675; basically PG ruleutils needs to call the `citus_ruleutils.c` functions added by #7675. --- src/backend/distributed/deparser/ruleutils_18.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/backend/distributed/deparser/ruleutils_18.c b/src/backend/distributed/deparser/ruleutils_18.c index bd044f5e7..44e4c8d38 100644 --- a/src/backend/distributed/deparser/ruleutils_18.c +++ b/src/backend/distributed/deparser/ruleutils_18.c @@ -3804,6 +3804,8 @@ get_update_query_targetlist_def(Query *query, List *targetList, SubLink *cur_ma_sublink; List *ma_sublinks; + targetList = ExpandMergedSubscriptingRefEntries(targetList); + /* * Prepare to deal with MULTIEXPR assignments: collect the source SubLinks * into a list. We expect them to appear, in ID order, in resjunk tlist @@ -3827,6 +3829,8 @@ get_update_query_targetlist_def(Query *query, List *targetList, } } } + + ensure_update_targetlist_in_param_order(targetList); } next_ma_cell = list_head(ma_sublinks); cur_ma_sublink = NULL;