XiaozongCui created SPARK-45806:
-----------------------------------

             Summary: GROUP BY ALL don't work in ansi mode
                 Key: SPARK-45806
                 URL: https://issues.apache.org/jira/browse/SPARK-45806
             Project: Spark
          Issue Type: Bug
          Components: SQL
    Affects Versions: 3.5.0, 3.4.0
            Reporter: XiaozongCui


I noticed that we treat 'ALL' in 'GROUP BY ALL' as an Identifier in parsing, 
and this will cause problem when I turn on ansi keyword behavior
*set spark.sql.ansi.enabled=true;*
*set spark.sql.ansi.enforceReservedKeywords=true;*

spark-sql (default)> select a,b,c, count(*) from values(1,2,3)t(a,b,c) group by 
all;

[PARSE_SYNTAX_ERROR] Syntax error at or near 'all'.(line 1, pos 59)

== SQL ==
select a,b,c, count(*) from values(1,2,3)t(a,b,c) group by all
-----------------------------------------------------------^^^

can we allow this reserved keyword in ansi mode ?



--
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