* makeTargetEntry - * creates a TargetEntry node */
| 237 | * creates a TargetEntry node |
| 238 | */ |
| 239 | TargetEntry * |
| 240 | makeTargetEntry(Expr *expr, |
| 241 | AttrNumber resno, |
| 242 | char *resname, |
| 243 | bool resjunk) |
| 244 | { |
| 245 | TargetEntry *tle = makeNode(TargetEntry); |
| 246 | |
| 247 | tle->expr = expr; |
| 248 | tle->resno = resno; |
| 249 | tle->resname = resname; |
| 250 | |
| 251 | /* |
| 252 | * We always set these fields to 0. If the caller wants to change them he |
| 253 | * must do so explicitly. Few callers do that, so omitting these |
| 254 | * arguments reduces the chance of error. |
| 255 | */ |
| 256 | tle->ressortgroupref = 0; |
| 257 | tle->resorigtbl = InvalidOid; |
| 258 | tle->resorigcol = 0; |
| 259 | |
| 260 | tle->resjunk = resjunk; |
| 261 | |
| 262 | return tle; |
| 263 | } |
| 264 | |
| 265 | /* |
| 266 | * flatCopyTargetEntry - |
no outgoing calls
no test coverage detected