]> granicus.if.org Git - postgresql/commitdiff
Remove 'target' from GroupPathExtraData.
authorRobert Haas <rhaas@postgresql.org>
Thu, 29 Mar 2018 20:17:18 +0000 (16:17 -0400)
committerRobert Haas <rhaas@postgresql.org>
Thu, 29 Mar 2018 20:17:18 +0000 (16:17 -0400)
It's not needed.

Jeevan Chalke

Discussion: http://postgr.es/m/CAM2+6=XPWujjmj5zUaBTGDoB38CemwcPmjkRy0qOcsQj_V+2sQ@mail.gmail.com

src/backend/optimizer/plan/planner.c
src/include/nodes/relation.h

index 359f3fc974aeed792eb8b6537510f3cac914b2d7..60e2f21d9878fc82dc46212b5ff2a32abe582409 100644 (file)
@@ -3744,7 +3744,6 @@ create_grouping_paths(PlannerInfo *root,
                        flags |= GROUPING_CAN_PARTIAL_AGG;
 
                extra.flags = flags;
-               extra.target = target;
                extra.target_parallel_safe = target_parallel_safe;
                extra.havingQual = parse->havingQual;
                extra.targetList = parse->targetList;
@@ -7029,7 +7028,7 @@ create_partitionwise_grouping_paths(PlannerInfo *root,
        int                     cnt_parts;
        List       *grouped_live_children = NIL;
        List       *partially_grouped_live_children = NIL;
-       PathTarget *target = extra->target;
+       PathTarget *target = grouped_rel->reltarget;
 
        Assert(patype != PARTITIONWISE_AGGREGATE_NONE);
        Assert(patype != PARTITIONWISE_AGGREGATE_PARTIAL ||
@@ -7062,7 +7061,6 @@ create_partitionwise_grouping_paths(PlannerInfo *root,
                        adjust_appendrel_attrs(root,
                                                                   (Node *) target->exprs,
                                                                   nappinfos, appinfos);
-               child_extra.target = child_target;
 
                /* Translate havingQual and targetList. */
                child_extra.havingQual = (Node *)
index abbbda9e91f5838cf629e055f39743d506ca9b8a..2b4f773c70ae8b002e585e3153df713cb40f3f1e 100644 (file)
@@ -2340,7 +2340,6 @@ typedef enum
  *             have been initialized.
  * agg_partial_costs gives partial aggregation costs.
  * agg_final_costs gives finalization costs.
- * target is the PathTarget to be used while creating paths.
  * target_parallel_safe is true if target is parallel safe.
  * havingQual gives list of quals to be applied after aggregation.
  * targetList gives list of columns to be projected.
@@ -2355,7 +2354,6 @@ typedef struct
        AggClauseCosts agg_final_costs;
 
        /* Data which may differ across partitions. */
-       PathTarget *target;
        bool            target_parallel_safe;
        Node       *havingQual;
        List       *targetList;