You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Julian Hyde (JIRA)" <ji...@apache.org> on 2015/04/08 19:02:12 UTC

[jira] [Created] (CALCITE-675) Add planner rule that removes simple Project beneath Aggregate

Julian Hyde created CALCITE-675:
-----------------------------------

             Summary: Add planner rule that removes simple Project beneath Aggregate
                 Key: CALCITE-675
                 URL: https://issues.apache.org/jira/browse/CALCITE-675
             Project: Calcite
          Issue Type: Bug
            Reporter: Julian Hyde
            Assignee: Julian Hyde


If you have a simple Project that just re-orders or renames fields, or projects a subset, and it is directly beneath an Aggregate, then the Aggregate can be rewritten in terms of the Project's input.

This rule should also apply if the project computes expressions, if those expressions are not used.

This rule will help AggegateJoinTransposeRule apply in more cases. For example, it cannot currently apply to {code}select distinct dept.deptno from emp join dept using (deptno){code} because the join projects 2 columns and the aggregate only uses one.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)