← Back to Overview

src/backend/parser/analyze.c

Coverage: 61/62 lines (98.4%)
Total Lines
62
modified
Covered
61
98.4%
Uncovered
1
1.6%
키보드 네비게이션
transformSetOperationTree() lines 2078-2247
Modified Lines Coverage: 3/3 lines (100.0%)
LineHitsSourceCommit
2078 - transformSetOperationTree(ParseState *pstate, SelectStmt *stmt, -
2079 - bool isTopLevel, List **targetlist) -
2080 - { -
2081 - bool isLeaf; -
2082 - -
2083 - Assert(stmt && IsA(stmt, SelectStmt)); -
2084 - -
2085 - /* Guard against stack overflow due to overly complex set-expressions */ -
2086 - check_stack_depth(); -
2087 - -
2088 - /* -
2089 - * Validity-check both leaf and internal SELECTs for disallowed ops. -
2090 - */ -
2091 - if (stmt->intoClause) -
2092 - ereport(ERROR, -
2093 - (errcode(ERRCODE_SYNTAX_ERROR), -
2094 - errmsg("INTO is only allowed on first SELECT of UNION/INTERSECT/EXCEPT"), -
2095 - parser_errposition(pstate, -
2096 - exprLocation((Node *) stmt->intoClause)))); -
2097 - -
2098 - /* We don't support FOR UPDATE/SHARE with set ops at the moment. */ -
2099 - if (stmt->lockingClause) -
2100 - ereport(ERROR, -
2101 - (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), -
2102 - /*------ -
2103 - translator: %s is a SQL row locking clause such as FOR UPDATE */ -
2104 - errmsg("%s is not allowed with UNION/INTERSECT/EXCEPT", -
2105 - LCS_asString(((LockingClause *) -
2106 - linitial(stmt->lockingClause))->strength)))); -
2107 - -
2108 - /* -
2109 - * If an internal node of a set-op tree has ORDER BY, LIMIT, FOR UPDATE, -
2110 - * or WITH clauses attached, we need to treat it like a leaf node to -
2111 - * generate an independent sub-Query tree. Otherwise, it can be -
2112 - * represented by a SetOperationStmt node underneath the parent Query. -
2113 - */ -
2114 - if (stmt->op == SETOP_NONE) -
2115 - { -
2116 - Assert(stmt->larg == NULL && stmt->rarg == NULL); -
2117 - isLeaf = true; -
2118 - } -
2119 - else -
2120 - { -
2121 - Assert(stmt->larg != NULL && stmt->rarg != NULL); -
2122 - if (stmt->sortClause || stmt->limitOffset || stmt->limitCount || -
2123 - stmt->lockingClause || stmt->withClause) -
2124 - isLeaf = true; -
2125 - else -
2126 - isLeaf = false; -
2127 - } -
2128 - -
2129 - if (isLeaf) -
2130 - { -
2131 - /* Process leaf SELECT */ -
2132 - Query *selectQuery; -
2133 - ParseNamespaceItem *nsitem; -
2134 - RangeTblRef *rtr; -
2135 - -
2136 - /* -
2137 - * Transform SelectStmt into a Query. -
2138 - * -
2139 - * This works the same as SELECT transformation normally would, except -
2140 - * that we prevent resolving unknown-type outputs as TEXT. This does -
2141 - * not change the subquery's semantics since if the column type -
2142 - * matters semantically, it would have been resolved to something else -
2143 - * anyway. Doing this lets us resolve such outputs using -
2144 - * select_common_type(), below. -
2145 - * -
2146 - * Note: previously transformed sub-queries don't affect the parsing -
2147 - * of this sub-query, because they are not in the toplevel pstate's -
2148 - * namespace list. -
2149 - */ -
2150 - selectQuery = parse_sub_analyze((Node *) stmt, pstate, -
2151 - NULL, false, false); -
2152 - -
2153 - /* -
2154 - * Check for bogus references to Vars on the current query level (but -
2155 - * upper-level references are okay). Normally this can't happen -
2156 - * because the namespace will be empty, but it could happen if we are -
2157 - * inside a rule. -
2158 - */ -
2159 - if (pstate->p_namespace) -
2160 - { -
2161 - if (contain_vars_of_level((Node *) selectQuery, 1)) -
2162 - ereport(ERROR, -
2163 - (errcode(ERRCODE_INVALID_COLUMN_REFERENCE), -
2164 - errmsg("UNION/INTERSECT/EXCEPT member statement cannot refer to other relations of same query level"), -
2165 - parser_errposition(pstate, -
2166 - locate_var_of_level((Node *) selectQuery, 1)))); -
2167 - } -
2168 - -
2169 - /* -
2170 - * Extract a list of the non-junk TLEs for upper-level processing. -
2171 - */ -
2172 - if (targetlist) -
2173 - { -
2174 16974 ListCell *tl; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2175 - 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2176 - *targetlist = NIL; -
2177 - foreach(tl, selectQuery->targetList) -
2178 - { -
2179 - TargetEntry *tle = (TargetEntry *) lfirst(tl); -
2180 - -
2181 - if (!tle->resjunk) -
2182 - *targetlist = lappend(*targetlist, tle); -
2183 - } -
2184 - } -
2185 - -
2186 - /* -
2187 - * Make the leaf query be a subquery in the top-level rangetable. -
2188 - */ -
2189 - nsitem = addRangeTableEntryForSubquery(pstate, -
2190 - selectQuery, -
2191 - NULL, -
2192 - false, -
2193 - false); -
2194 - -
2195 - /* -
2196 - * Return a RangeTblRef to replace the SelectStmt in the set-op tree. -
2197 - */ -
2198 - rtr = makeNode(RangeTblRef); -
2199 - rtr->rtindex = nsitem->p_rtindex; -
2200 - return (Node *) rtr; -
2201 - } -
2202 - else -
2203 - { -
2204 - /* Process an internal node (set operation node) */ -
2205 - SetOperationStmt *op = makeNode(SetOperationStmt); -
2206 - List *ltargetlist; -
2207 - List *rtargetlist; -
2208 - const char *context; -
2209 - bool recursive = (pstate->p_parent_cte && -
2210 - pstate->p_parent_cte->cterecursive); -
2211 - -
2212 - context = (stmt->op == SETOP_UNION ? "UNION" : -
2213 - (stmt->op == SETOP_INTERSECT ? "INTERSECT" : -
2214 - "EXCEPT")); -
2215 - -
2216 - op->op = stmt->op; -
2217 - op->all = stmt->all; -
2218 - -
2219 - /* -
2220 - * Recursively transform the left child node. -
2221 - */ -
2222 - op->larg = transformSetOperationTree(pstate, stmt->larg, -
2223 - false, -
2224 - &ltargetlist); -
2225 - -
2226 - /* -
2227 - * If we are processing a recursive union query, now is the time to -
2228 - * examine the non-recursive term's output columns and mark the -
2229 - * containing CTE as having those result columns. We should do this -
2230 - * only at the topmost setop of the CTE, of course. -
2231 - */ -
2232 - if (isTopLevel && recursive) -
2233 - determineRecursiveColTypes(pstate, op->larg, ltargetlist); -
2234 - -
2235 - /* -
2236 - * Recursively transform the right child node. -
2237 - */ -
2238 - op->rarg = transformSetOperationTree(pstate, stmt->rarg, -
2239 - false, -
2240 - &rtargetlist); -
2241 - -
2242 10271 constructSetOpTargetlist(op, ltargetlist, rtargetlist, targetlist, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2243 - context, pstate, recursive); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2244 - -
2245 10250 return (Node *) op; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2246 - } 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2247 - } 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
constructSetOpTargetlist() lines 2261-2418
Modified Lines Coverage: 58/59 lines (98.3%)
LineHitsSourceCommit
2261 10539 constructSetOpTargetlist(SetOperationStmt *op, List *ltargetlist, List *rtargetlist, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2262 - List **targetlist, const char *context, ParseState *pstate, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2263 - bool recursive) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2264 - { 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2265 10539 ListCell *ltl; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2266 10539 ListCell *rtl; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2267 - -
2268 - /* 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2269 - * Verify that the two children have the same number of non-junk columns, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2270 - * and determine the types of the merged output columns. 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2271 - */ 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2272 31497 if (list_length(ltargetlist) != list_length(rtargetlist)) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2273 0 ereport(ERROR, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2274 - (errcode(ERRCODE_SYNTAX_ERROR), 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2275 - errmsg("each %s query must have the same number of columns", 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2276 - context), 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2277 - parser_errposition(pstate, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2278 - exprLocation((Node *) rtargetlist)))); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2279 - -
2280 10539 if (targetlist) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2281 3757 *targetlist = NIL; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2282 10539 op->colTypes = NIL; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2283 10539 op->colTypmods = NIL; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2284 10539 op->colCollations = NIL; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2285 10539 op->groupClauses = NIL; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2286 - -
2287 43767 forboth(ltl, ltargetlist, rtl, rtargetlist) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2288 - { 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2289 33249 TargetEntry *ltle = (TargetEntry *) lfirst(ltl); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2290 33249 TargetEntry *rtle = (TargetEntry *) lfirst(rtl); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2291 33249 Node *lcolnode = (Node *) ltle->expr; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2292 33249 Node *rcolnode = (Node *) rtle->expr; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2293 33249 Oid lcoltype = exprType(lcolnode); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2294 33249 Oid rcoltype = exprType(rcolnode); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2295 33249 Node *bestexpr; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2296 33249 int bestlocation; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2297 33249 Oid rescoltype; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2298 33249 int32 rescoltypmod; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2299 33249 Oid rescolcoll; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2300 - 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2301 - /* select common type, same as CASE et al */ 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2302 33249 rescoltype = select_common_type(pstate, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2303 33249 list_make2(lcolnode, rcolnode), 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2304 - context, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2305 - &bestexpr); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2306 33249 bestlocation = exprLocation(bestexpr); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2307 - -
2308 - /* 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2309 - * Verify the coercions are actually possible. If not, we'd fail 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2310 - * later anyway, but we want to fail now while we have sufficient 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2311 - * context to produce an error cursor position. 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2312 - * 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2313 - * For all non-UNKNOWN-type cases, we verify coercibility but we don't 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2314 - * modify the child's expression, for fear of changing the child 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2315 - * query's semantics. 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2316 - * 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2317 - * If a child expression is an UNKNOWN-type Const or Param, we want to 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2318 - * replace it with the coerced expression. This can only happen when 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2319 - * the child is a leaf set-op node. It's safe to replace the 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2320 - * expression because if the child query's semantics depended on the 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2321 - * type of this output column, it'd have already coerced the UNKNOWN 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2322 - * to something else. We want to do this because (a) we want to 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2323 - * verify that a Const is valid for the target type, or resolve the 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2324 - * actual type of an UNKNOWN Param, and (b) we want to avoid 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2325 - * unnecessary discrepancies between the output type of the child 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2326 - * query and the resolved target type. Such a discrepancy would 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2327 - * disable optimization in the planner. 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2328 - * 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2329 - * If it's some other UNKNOWN-type node, eg a Var, we do nothing 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2330 - * (knowing that coerce_to_common_type would fail). The planner is 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2331 - * sometimes able to fold an UNKNOWN Var to a constant before it has 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2332 - * to coerce the type, so failing now would just break cases that 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2333 - * might work. 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2334 - */ 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2335 33249 if (lcoltype != UNKNOWNOID) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2336 30008 lcolnode = coerce_to_common_type(pstate, lcolnode, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2337 - rescoltype, context); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2338 3241 else if (IsA(lcolnode, Const) || 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2339 - IsA(lcolnode, Param)) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2340 - { 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2341 3241 lcolnode = coerce_to_common_type(pstate, lcolnode, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2342 - rescoltype, context); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2343 3241 ltle->expr = (Expr *) lcolnode; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2344 - } 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2345 - -
2346 33249 if (rcoltype != UNKNOWNOID) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2347 29534 rcolnode = coerce_to_common_type(pstate, rcolnode, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2348 - rescoltype, context); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2349 3715 else if (IsA(rcolnode, Const) || 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2350 - IsA(rcolnode, Param)) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2351 - { 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2352 3715 rcolnode = coerce_to_common_type(pstate, rcolnode, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2353 - rescoltype, context); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2354 3712 rtle->expr = (Expr *) rcolnode; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2355 - } 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2356 - -
2357 33246 rescoltypmod = select_common_typmod(pstate, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2358 33246 list_make2(lcolnode, rcolnode), 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2359 - rescoltype); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2360 - -
2361 - /* 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2362 - * Select common collation. A common collation is required for all 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2363 - * set operators except UNION ALL; see SQL:2008 7.13 <query 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2364 - * expression> Syntax Rule 15c. (If we fail to identify a common 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2365 - * collation for a UNION ALL column, the colCollations element will be 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2366 - * set to InvalidOid, which may result in a runtime error if something 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2367 - * at a higher query level wants to use the column's collation.) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2368 - */ 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2369 33246 rescolcoll = select_common_collation(pstate, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2370 33246 list_make2(lcolnode, rcolnode), 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2371 33246 (op->op == SETOP_UNION && op->all)); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2372 - -
2373 - /* emit results */ 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2374 33228 op->colTypes = lappend_oid(op->colTypes, rescoltype); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2375 33228 op->colTypmods = lappend_int(op->colTypmods, rescoltypmod); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2376 33228 op->colCollations = lappend_oid(op->colCollations, rescolcoll); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2377 - -
2378 - /* 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2379 - * For all cases except UNION ALL, identify the grouping operators 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2380 - * (and, if available, sorting operators) that will be used to 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2381 - * eliminate duplicates. 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2382 - */ 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2383 33228 if (op->op != SETOP_UNION || !op->all) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2384 - { 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2385 13589 ParseCallbackState pcbstate; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2386 - 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2387 13589 setup_parser_errposition_callback(&pcbstate, pstate, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2388 - bestlocation); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2389 - 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2390 - /* If it's a recursive union, we need to require hashing support. */ 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2391 13589 op->groupClauses = lappend(op->groupClauses, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2392 13589 makeSortGroupClauseForSetOp(rescoltype, recursive)); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2393 - 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2394 13589 cancel_parser_errposition_callback(&pcbstate); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2395 - } -
2396 - -
2397 - /* 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2398 - * Construct a dummy tlist entry to return. We use a SetToDefault 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2399 - * node for the expression, since it carries exactly the fields 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2400 - * needed, but any other expression node type would do as well. 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2401 - */ 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2402 33228 if (targetlist) 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2403 - { 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2404 16267 SetToDefault *rescolnode = makeNode(SetToDefault); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2405 16267 TargetEntry *restle; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2406 - 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2407 16267 rescolnode->typeId = rescoltype; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2408 16267 rescolnode->typeMod = rescoltypmod; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2409 16267 rescolnode->collation = rescolcoll; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2410 16267 rescolnode->location = bestlocation; 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2411 16267 restle = makeTargetEntry((Expr *) rescolnode, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2412 - 0, /* no need to set resno */ 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2413 - NULL, 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2414 - false); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2415 16267 *targetlist = lappend(*targetlist, restle); 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2416 - } 86c14eaWIP: SQL Property Graph Queries (SQL/PGQ)
2417 - } -
2418 - } -