[ https://issues.apache.org/jira/browse/SPARK-32983?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Will Du resolved SPARK-32983. ----------------------------- Resolution: Not A Problem [~petertoth]. You are correct. I close this issue as not a problem. > Spark SQL INTERSECT ALL does not keep all rows. > ----------------------------------------------- > > Key: SPARK-32983 > URL: https://issues.apache.org/jira/browse/SPARK-32983 > Project: Spark > Issue Type: Bug > Components: SQL > Affects Versions: 2.4.6, 3.0.0, 3.0.1 > Reporter: Will Du > Priority: Major > > Spark SQL INTERSECT ALL should keep all rows. But, it actually remove > replicated like Spark SQL INTERSECT. > with base as ( > select 1 as id union all select 2 as id > ), a as ( > select 1 as id union all select 3 as id) > select * from a INTERSECT ALL select * from base; > > with base as ( > select 1 as id union all select 2 as id > ), a as ( > select 1 as id union all select 3 as id) > select * from a INTERSECT select * from base; > > Both the above queries return one record that is 1. > I think the 1st query should return > 1 > 1 -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org