Hello Aman Sinha, Impala Public Jenkins,

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/16663

to look at the new patch set (#4).

Change subject: IMPALA-10295: fix analytic limit pushdown with no predicates
......................................................................

IMPALA-10295: fix analytic limit pushdown with no predicates

This handles the first case where analytic limit pushdown could be
applied incorrectly: when there are no predicates applied to the
output of the analytic.

If no rows are filtered out between the pre-analytic sort and the place
where the top-N will be inserted, and the order matches exactly, we
can push down the limit safely because the limit below the analytic
will filter exactly the same rows as the limit above the analytic
would.

We add a helper to check if the sort order matches exactly and then
handle the case with no select node correctly.

We leave the other cases where there is a special predicate to be
handled in the next patch of the series, as the logic there is a
bit more subtle.

Tests:
Added regression planner and query tests that demonstrate the problem.

Ran core tests.

Change-Id: I254e85edd5ea6b6e76d20cbdf27fd88059a98a21
---
M fe/src/main/java/org/apache/impala/planner/AnalyticEvalNode.java
M 
testdata/workloads/functional-planner/queries/PlannerTest/limit-pushdown-analytic.test
M testdata/workloads/tpch/queries/limit-pushdown-analytic.test
3 files changed, 238 insertions(+), 39 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/63/16663/4
--
To view, visit http://gerrit.cloudera.org:8080/16663
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I254e85edd5ea6b6e76d20cbdf27fd88059a98a21
Gerrit-Change-Number: 16663
Gerrit-PatchSet: 4
Gerrit-Owner: Tim Armstrong <tarmstr...@cloudera.com>
Gerrit-Reviewer: Aman Sinha <amsi...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <impala-public-jenk...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <tarmstr...@cloudera.com>

Reply via email to