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

Dongjoon Hyun commented on SPARK-40562:
---------------------------------------

I updated the Fix Version from 3.3.1 to 3.3.2 because 3.3.1 RC2 vote start 
without this.

> Add spark.sql.legacy.groupingIdWithAppendedUserGroupBy
> ------------------------------------------------------
>
>                 Key: SPARK-40562
>                 URL: https://issues.apache.org/jira/browse/SPARK-40562
>             Project: Spark
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 3.4.0, 3.3.1, 3.2.3
>            Reporter: Dongjoon Hyun
>            Assignee: Dongjoon Hyun
>            Priority: Major
>             Fix For: 3.4.0, 3.2.3, 3.3.2
>
>
> {code:java}
> scala> sql("SELECT count(*), grouping__id from (VALUES (1,1,1),(2,2,2)) AS 
> t(k1,k2,v) GROUP BY k1 GROUPING SETS (k2) ").show()
> +--------+------------+
> |count(1)|grouping__id|
> +--------+------------+
> |       1|           2|
> |       1|           2|
> +--------+------------+
> scala> sql("set spark.sql.legacy.groupingIdWithAppendedUserGroupBy=true")
> res1: org.apache.spark.sql.DataFrame = [key: string, value: string]scala> 
> sql("SELECT count(*), grouping__id from (VALUES (1,1,1),(2,2,2)) AS 
> t(k1,k2,v) GROUP BY k1 GROUPING SETS (k2) ").show()
> +--------+------------+
> |count(1)|grouping__id|
> +--------+------------+
> |       1|           1|
> |       1|           1|
> +--------+------------+ {code}



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