Handle nodes that may appear in GraphPattern expression trees
Peter Eisentraut <peter@eisentraut.org>
Author:
Peter Eisentraut <peter@eisentraut.org>
Date: 2026-05-04T15:34:32Z
Releases:
19 (unreleased)
Handle nodes that may appear in GraphPattern expression trees expression_tree_mutator_impl() did not handle T_GraphPattern, T_GraphElementPattern, and T_GraphPropertyRef. The corresponding expression_tree_walker_impl() already handles all three node types. This causes an "unrecognized node type" error whenever a GRAPH_TABLE appeared in an expression tree. While at it, also update raw_expression_tree_walker() and expression_tree_walker() to handle missing nodes that may appear in GraphPattern expression trees. When raw_expression_tree_walker() is called, GraphElementPattern::labelexpr contains ColumnRefs instead of GraphLabelRefs. Hence those are not handled in raw_expression_tree_walker(). Author: Satyanarayana Narlapuram <satyanarlapuram@gmail.com> Author: Ashutosh Bapat <ashutosh.bapat.oss@gmail.com> Reviewed-by: Robert Haas <robertmhaas@gmail.com> Discussion: https://www.postgresql.org/message-id/flat/CAHg%2BQDc97WFTSkXg%3Dg_ZAH8GnY2gJrvq72cs%2BYjqEAuZgXnkAQ%40mail.gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/nodes/nodeFuncs.c | modified | +31 −0 |
| src/test/regress/expected/graph_table.out | modified | +11 −0 |
| src/test/regress/sql/graph_table.sql | modified | +5 −0 |
Discussion
- [Patch]Add Graph* node support to expression_tree_mutator 7 messages · 2026-04-21 → 2026-05-11