File tree 1 file changed +1
-16
lines changed
src/backend/optimizer/plan
1 file changed +1
-16
lines changed Original file line number Diff line number Diff line change 8
8
*
9
9
*
10
10
* IDENTIFICATION
11
- * $PostgreSQL: pgsql/src/backend/optimizer/plan/planner.c,v 1.229 2008/03/28 02: 00:11 tgl Exp $
11
+ * $PostgreSQL: pgsql/src/backend/optimizer/plan/planner.c,v 1.230 2008/03/29 00:15:28 tgl Exp $
12
12
*
13
13
*-------------------------------------------------------------------------
14
14
*/
@@ -835,21 +835,6 @@ grouping_planner(PlannerInfo *root, double tuple_fraction)
835
835
836
836
MemSet (& agg_counts , 0 , sizeof (AggClauseCounts ));
837
837
838
- /*
839
- * If the query involves ungrouped aggregation, then it can produce
840
- * at most one row, so we can ignore any ORDER BY or DISTINCT
841
- * request. This isn't all that exciting as an optimization, but it
842
- * prevents a corner case when optimize_minmax_aggregates succeeds:
843
- * if ORDER BY or DISTINCT were present we'd try, and fail, to match
844
- * the EquivalenceClasses we're about to build with the modified
845
- * targetlist entries it will create.
846
- */
847
- if (parse -> hasAggs && parse -> groupClause == NIL )
848
- {
849
- parse -> sortClause = NIL ;
850
- parse -> distinctClause = NIL ;
851
- }
852
-
853
838
/* Preprocess targetlist */
854
839
tlist = preprocess_targetlist (root , tlist );
855
840
You can’t perform that action at this time.
0 commit comments