somani commented on a change in pull request #34470:
URL: https://github.com/apache/spark/pull/34470#discussion_r741934796
##########
File path: sql/core/src/test/scala/org/apache/spark/sql/SubquerySuite.scala
##########
@@ -1931,18 +1931,29 @@ class SubquerySuite extends QueryTest with
SharedSparkSession with AdaptiveSpark
sql(
"""
|SELECT c1, s, s * 10 FROM (
- | SELECT c1, (SELECT FIRST(c2) FROM t2 WHERE t1.c1 = t2.c1) s
FROM t1)
+ | SELECT c1, (SELECT MIN(c2) FROM t2 WHERE t1.c1 = t2.c1) s FROM
t1)
Review comment:
This one is fine, but the one below fails with:
```Failed to analyze query: org.apache.spark.sql.AnalysisException:
nondeterministic expression sum(scalarsubquery(t1.c1)) should not appear in the
arguments of an aggregate function.;```
##########
File path: sql/core/src/test/scala/org/apache/spark/sql/SubquerySuite.scala
##########
@@ -1931,18 +1931,29 @@ class SubquerySuite extends QueryTest with
SharedSparkSession with AdaptiveSpark
sql(
"""
|SELECT c1, s, s * 10 FROM (
- | SELECT c1, (SELECT FIRST(c2) FROM t2 WHERE t1.c1 = t2.c1) s
FROM t1)
+ | SELECT c1, (SELECT MIN(c2) FROM t2 WHERE t1.c1 = t2.c1) s FROM
t1)
Review comment:
This one is fine, but the one below fails with:
```Failed to analyze query: org.apache.spark.sql.AnalysisException:
nondeterministic expression sum(scalarsubquery(t1.c1)) should not appear in the
arguments of an aggregate function.;```
--
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]