[ 
https://issues.apache.org/jira/browse/IMPALA-15189?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Quanlong Huang resolved IMPALA-15189.
-------------------------------------
    Fix Version/s: Impala 5.0.0
       Resolution: Fixed

> HBO for computing SortNode cardinality
> --------------------------------------
>
>                 Key: IMPALA-15189
>                 URL: https://issues.apache.org/jira/browse/IMPALA-15189
>             Project: IMPALA
>          Issue Type: New Feature
>            Reporter: Quanlong Huang
>            Assignee: Quanlong Huang
>            Priority: Major
>             Fix For: Impala 5.0.0
>
>
> A sort only reorders rows, so its output row count equals its child's 
> *unless* it applies a limit: TopN, Partitioned TopN, or a total sort carrying 
> a LIMIT.
> For instance, the SortNode created for the following analytic function is a 
> Partitioned TopN:
> {code:sql}
> select ..., rank() over (partition by a order by b) rnk ... where rnk < 
> 5"{code}
> Its output cardinality depends on the distinct number of column a and the 
> per-partition limit 5.
> HBO should track cardinality for SortNodes when they are not 
> cardinality-preserving.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to