You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@impala.apache.org by "kamal Maheshwari (JIRA)" <ji...@apache.org> on 2018/02/16 04:15:00 UTC

[jira] [Created] (IMPALA-6534) Impala query planner should be smart to remove extra GROUP BY

kamal Maheshwari created IMPALA-6534:
----------------------------------------

             Summary: Impala query planner should be smart to remove extra GROUP BY
                 Key: IMPALA-6534
                 URL: https://issues.apache.org/jira/browse/IMPALA-6534
             Project: IMPALA
          Issue Type: Improvement
          Components: Backend
    Affects Versions: Impala 2.11.0
            Reporter: kamal Maheshwari
         Attachments: Query_cte_explain_plan.txt, Query_cte_profile.txt, Query_no_cte_explain_plan.txt, Query_no_cte_profile.txt, query_cte.hql, query_no_cte.hql

A customer shared a complex query (attached) from their existing DB environment which uses CTE. They noticed that the query didn't finish as-is. They took out the CTE block and the query finished quickly.

I then suggested to take out the GROUP BY from the CTE block and the query finished fairly quickly.

The ask is - if the planner can detect such situations and do the right thing. These are common scenarios for workload migrations.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)