Github user nsyca commented on a diff in the pull request:
https://github.com/apache/spark/pull/16467#discussion_r94519375
--- Diff: sql/core/src/test/scala/org/apache/spark/sql/SubquerySuite.scala
---
@@ -263,12 +263,12 @@ class SubquerySuite extends QueryTest with
SharedSQLContext {
Row(1, 2.0) :: Row(1, 2.0) :: Nil)
checkAnswer(
- sql("select * from l where a not in (select c from t where b < d)"),
- Row(1, 2.0) :: Row(1, 2.0) :: Row(3, 3.0) :: Nil)
+ sql("select * from l where (a, b) not in (select c, d from t) and a
< 4"),
+ Row(1, 2.0) :: Row(1, 2.0) :: Row(2, 1.0) :: Row(2, 1.0) :: Row(3,
3.0) :: Nil)
// Empty sub-query
checkAnswer(
- sql("select * from l where a not in (select c from r where c > 10
and b < d)"),
+ sql("select * from l where (a, b) not in (select c, d from r where c
> 10)"),
--- End diff --
With the predicate `c > 10` (which filters all the rows in the subquery),
it covers up the correlated predicate problem. Instead of removing the test
case completely, I just modify to have a different coverage for multiple
columns.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]