Hi Henson,

> Attached is the v47 patches for Row pattern recognition (SQL/RPR).

While looking into v47, I noticed that
raw_expression_tree_walker_impl() lacks tracking RPCommonSyntax and
its children nodes. Probably this does nothing wrong with RPR
functionalities but just for completeness I created a patch on top of
v47.

Regards,
--
Tatsuo Ishii
SRA OSS K.K.
English: http://www.sraoss.co.jp/index_en/
Japanese:http://www.sraoss.co.jp
diff --git a/src/backend/nodes/nodeFuncs.c b/src/backend/nodes/nodeFuncs.c
index 651d049cfa2..c8694726e3c 100644
--- a/src/backend/nodes/nodeFuncs.c
+++ b/src/backend/nodes/nodeFuncs.c
@@ -4612,6 +4612,8 @@ raw_expression_tree_walker_impl(Node *node,
                                        return true;
                                if (WALK(wd->endOffset))
                                        return true;
+                               if (WALK(wd->rpCommonSyntax))
+                                       return true;
                        }
                        break;
                case T_RangeSubselect:
@@ -4865,6 +4867,24 @@ raw_expression_tree_walker_impl(Node *node,
                                        return true;
                        }
                        break;
+               case T_RPCommonSyntax:
+                       {
+                               RPCommonSyntax *rc = (RPCommonSyntax *) node;
+
+                               if (WALK(rc->rpPattern))
+                                       return true;
+                               if (WALK(rc->rpDefs))
+                                       return true;
+                       }
+                       break;
+               case T_RPRPatternNode:
+                       {
+                               RPRPatternNode *rp = (RPRPatternNode *) node;
+
+                               if (WALK(rp->children))
+                                       return true;
+                       }
+                       break;
                default:
                        elog(ERROR, "unrecognized node type: %d",
                                 (int) nodeTag(node));

Reply via email to