* Walker for assign_query_collations * * Each expression found by query_tree_walker is processed independently. * Note that query_tree_walker may pass us a whole List, such as the * targetlist, in which case each subexpression must be processed * independently --- we don't want to bleat if two different targetentries * have different collations. */
| 123 | * have different collations. |
| 124 | */ |
| 125 | static bool |
| 126 | assign_query_collations_walker(Node *node, ParseState *pstate) |
| 127 | { |
| 128 | /* Need do nothing for empty subexpressions */ |
| 129 | if (node == NULL) |
| 130 | return false; |
| 131 | |
| 132 | /* |
| 133 | * We don't want to recurse into a set-operations tree; it's already been |
| 134 | * fully processed in transformSetOperationStmt. |
| 135 | */ |
| 136 | if (IsA(node, SetOperationStmt)) |
| 137 | return false; |
| 138 | |
| 139 | if (IsA(node, List)) |
| 140 | assign_list_collations(pstate, (List *) node); |
| 141 | else |
| 142 | assign_expr_collations(pstate, node); |
| 143 | |
| 144 | return false; |
| 145 | } |
| 146 | |
| 147 | /* |
| 148 | * assign_list_collations() |
nothing calls this directly
no test coverage detected