You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "N Campbell (JIRA)" <ji...@apache.org> on 2019/05/21 14:12:00 UTC
[jira] [Commented] (SPARK-20827) cannot express HAVING without a
GROUP BY clause
[ https://issues.apache.org/jira/browse/SPARK-20827?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16844872#comment-16844872 ]
N Campbell commented on SPARK-20827:
------------------------------------
An enhancement was bulk closed and incomplete. No reason given.
Unclear if APACHE SPARK team saying they have no intent of ever implementing the enhancement vs a script which clobbered things.
> cannot express HAVING without a GROUP BY clause
> -----------------------------------------------
>
> Key: SPARK-20827
> URL: https://issues.apache.org/jira/browse/SPARK-20827
> Project: Spark
> Issue Type: Improvement
> Components: SQL
> Affects Versions: 2.1.0
> Reporter: N Campbell
> Priority: Minor
> Labels: bulk-closed
>
> SPARK SQL does not support a HAVING clause without a GROUP BY which is valid SQL and supported by other engines (ORACLE, DB2, ....)
> SELECT
> 'AAAA' AS `C1`
> FROM
> `cert`.`tparts`
> HAVING
> COUNT(`pno`) > 0
> SQL state: java.lang.UnsupportedOperationException: Cannot evaluate expression: count(input[0, string, true]), Query: SELECT
> 'AAAA' AS `C1`
> FROM
> `cert`.`tparts`
> HAVING
> COUNT(`pno`) > 0.
> SQLState: HY000
> ErrorCode: 500051
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org