[
https://issues.apache.org/jira/browse/SPARK-49000?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
ASF GitHub Bot reassigned SPARK-49000:
--------------------------------------
Assignee: (was: Apache Spark)
> 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: [email protected]
For additional commands, e-mail: [email protected]