Github user geraldss commented on a diff in the pull request: https://github.com/apache/phoenix/pull/308#discussion_r205296128 --- Diff: phoenix-core/src/main/java/org/apache/phoenix/execute/ClientAggregatePlan.java --- @@ -183,13 +198,15 @@ public ExplainPlan getExplainPlan() throws SQLException { if (where != null) { planSteps.add("CLIENT FILTER BY " + where.toString()); } - if (!groupBy.isEmpty()) { - if (!groupBy.isOrderPreserving()) { - planSteps.add("CLIENT SORTED BY " + groupBy.getKeyExpressions().toString()); - } + if (groupBy.isEmpty()) { + planSteps.add("CLIENT AGGREGATE INTO SINGLE ROW"); + } else if (groupBy.isOrderPreserving()) { planSteps.add("CLIENT AGGREGATE INTO DISTINCT ROWS BY " + groupBy.getExpressions().toString()); + } else if (useHashAgg) { + planSteps.add("CLIENT HASH AGGREGATE INTO DISTINCT ROWS BY " + groupBy.getExpressions().toString()); --- End diff -- Done.
---