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

GridGain Integration commented on SPARK-49000:
----------------------------------------------

User 'uros-db' has created a pull request for this issue:
https://github.com/apache/spark/pull/47482

> Aggregation with DISTINCT gives wrong results when dealing with literals
> ------------------------------------------------------------------------
>
>                 Key: SPARK-49000
>                 URL: https://issues.apache.org/jira/browse/SPARK-49000
>             Project: Spark
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 3.0.0
>            Reporter: Uroš Bojanić
>            Priority: Critical
>              Labels: pull-request-available
>
> Aggregation with *DISTINCT* gives wrong results when dealing with literals. 
> It appears that this bug affects all (or most) released versions of Spark.
>  
> For example:
> {code:java}
> select count(distinct 1) from t{code}
> returns 1, while the correct result should be 0.
>  
> For reference:
> {code:java}
> select count(1) from t{code}
> returns 0, which is the correct and expected result.
>  
> In these examples, suppose that *t* is a table with any columns).



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

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

Reply via email to