dongjoon-hyun commented on a change in pull request #35353:
URL: https://github.com/apache/spark/pull/35353#discussion_r794255826
##########
File path:
sql/core/src/test/scala/org/apache/spark/sql/execution/adaptive/AdaptiveQueryExecSuite.scala
##########
@@ -187,6 +187,29 @@ class AdaptiveQueryExecSuite
}
}
+ test("Change broadcast join to merge join") {
+ withTable("t1", "t2") {
+ withSQLConf(
+ SQLConf.AUTO_BROADCASTJOIN_THRESHOLD.key -> "10000",
+ SQLConf.ADAPTIVE_AUTO_BROADCASTJOIN_THRESHOLD.key -> "-1",
+ SQLConf.SHUFFLE_PARTITIONS.key -> "1") {
+ sql("CREATE TABLE t1 USING PARQUET AS SELECT 1 c1")
+ sql("CREATE TABLE t2 USING PARQUET AS SELECT 1 c1")
+ val (plan, adaptivePlan) = runAdaptiveAndVerifyResult(
+ """
+ |SELECT * FROM (
+ | SELECT distinct c1 from t1
+ | )t1 JOIN (
Review comment:
nit. Could you add a space? `)t1` -> `) t1`?
##########
File path:
sql/core/src/test/scala/org/apache/spark/sql/execution/adaptive/AdaptiveQueryExecSuite.scala
##########
@@ -187,6 +187,29 @@ class AdaptiveQueryExecSuite
}
}
+ test("Change broadcast join to merge join") {
+ withTable("t1", "t2") {
+ withSQLConf(
+ SQLConf.AUTO_BROADCASTJOIN_THRESHOLD.key -> "10000",
+ SQLConf.ADAPTIVE_AUTO_BROADCASTJOIN_THRESHOLD.key -> "-1",
+ SQLConf.SHUFFLE_PARTITIONS.key -> "1") {
+ sql("CREATE TABLE t1 USING PARQUET AS SELECT 1 c1")
+ sql("CREATE TABLE t2 USING PARQUET AS SELECT 1 c1")
+ val (plan, adaptivePlan) = runAdaptiveAndVerifyResult(
+ """
+ |SELECT * FROM (
+ | SELECT distinct c1 from t1
+ | )t1 JOIN (
+ | SELECT distinct c1 from t2
+ | )t2 ON t1.c1 = t2.c1
Review comment:
ditto.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]