* assign_expr_collations() * Mark all nodes in the given expression tree with collation information. * * This is exported for the benefit of various utility commands that process * expressions without building a complete Query. It should be applied after * calling transformExpr() plus any expression-modifying operations such as * coerce_to_boolean(). */
| 174 | * coerce_to_boolean(). |
| 175 | */ |
| 176 | void |
| 177 | assign_expr_collations(ParseState *pstate, Node *expr) |
| 178 | { |
| 179 | assign_collations_context context; |
| 180 | |
| 181 | /* initialize context for tree walk */ |
| 182 | context.pstate = pstate; |
| 183 | context.collation = InvalidOid; |
| 184 | context.strength = COLLATE_NONE; |
| 185 | context.location = -1; |
| 186 | |
| 187 | /* and away we go */ |
| 188 | (void) assign_collations_walker(expr, &context); |
| 189 | } |
| 190 | |
| 191 | /* |
| 192 | * select_common_collation() |