[jira] [Assigned] (SPARK-42897) Avoid evaluate more than once for the variables from the left side in the FullOuter SMJ condition

2023-03-22 Thread Apache Spark (Jira)


 [ 
https://issues.apache.org/jira/browse/SPARK-42897?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Apache Spark reassigned SPARK-42897:


Assignee: Apache Spark

> Avoid evaluate more than once for the variables from the left side in the 
> FullOuter SMJ condition
> -
>
> Key: SPARK-42897
> URL: https://issues.apache.org/jira/browse/SPARK-42897
> Project: Spark
>  Issue Type: Improvement
>  Components: SQL
>Affects Versions: 3.4.0
>Reporter: Wan Kun
>Assignee: Apache Spark
>Priority: Minor
>
> Codegen issue for FullOuter SMJ,  for example
> {code}
> val df1 = spark.range(5).select($"id".as("k1"))
> val df2 = spark.range(10).select($"id".as("k2"))
> df1.join(df2.hint("SHUFFLE_MERGE"),
> $"k1" === $"k2" % 3 && $"k1" + 3 =!= $"k2" && $"k1" + 5 =!= $"k2", 
> "full_outer")
> {code}
> the join condition *$"k1" + 3 =!= $"k2" && $"k1" + 5 =!= $"k2"* both will 
> evaluate the variable *k1* and caused the codegen failed.



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



[jira] [Assigned] (SPARK-42897) Avoid evaluate more than once for the variables from the left side in the FullOuter SMJ condition

2023-03-22 Thread Apache Spark (Jira)


 [ 
https://issues.apache.org/jira/browse/SPARK-42897?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Apache Spark reassigned SPARK-42897:


Assignee: (was: Apache Spark)

> Avoid evaluate more than once for the variables from the left side in the 
> FullOuter SMJ condition
> -
>
> Key: SPARK-42897
> URL: https://issues.apache.org/jira/browse/SPARK-42897
> Project: Spark
>  Issue Type: Improvement
>  Components: SQL
>Affects Versions: 3.4.0
>Reporter: Wan Kun
>Priority: Minor
>
> Codegen issue for FullOuter SMJ,  for example
> {code}
> val df1 = spark.range(5).select($"id".as("k1"))
> val df2 = spark.range(10).select($"id".as("k2"))
> df1.join(df2.hint("SHUFFLE_MERGE"),
> $"k1" === $"k2" % 3 && $"k1" + 3 =!= $"k2" && $"k1" + 5 =!= $"k2", 
> "full_outer")
> {code}
> the join condition *$"k1" + 3 =!= $"k2" && $"k1" + 5 =!= $"k2"* both will 
> evaluate the variable *k1* and caused the codegen failed.



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