You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Zhenhua Wang (JIRA)" <ji...@apache.org> on 2017/10/06 14:46:00 UTC

[jira] [Commented] (SPARK-22179) percentile_approx should choose the first element if it already reaches the percentage

    [ https://issues.apache.org/jira/browse/SPARK-22179?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16194680#comment-16194680 ] 

Zhenhua Wang commented on SPARK-22179:
--------------------------------------

[~srowen] Yes, I planned to close this after the new issue is resolved :)

> percentile_approx should choose the first element if it already reaches the percentage
> --------------------------------------------------------------------------------------
>
>                 Key: SPARK-22179
>                 URL: https://issues.apache.org/jira/browse/SPARK-22179
>             Project: Spark
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 2.3.0
>            Reporter: Zhenhua Wang
>
> percentile_approx should choose the first element if it already reaches the percentage.
> For example, given input data 1 to 10, if a user queries 10% (or even less) percentile, it should return 1 (instead of 2), because the first value 1 already reaches 10%. Currently it returns a wrong answer: 2.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org