Github user mgaido91 commented on the issue:

    https://github.com/apache/spark/pull/22029
  
    @cloud-fan I agree with you that struct comparison behavior is 
questionable. But the IN (and NOT IN) behavior is coherent among Postgres, 
Oracle (and different from the current Spark behavior). This is the reason why 
I decided to propose to change only the behavior of the IN operator without 
changing the behavior of the struct comparison itself, which would be a much 
bigger change.
    
    Anyway, answering to your question, since this PR relates only to IN/NOT 
IN, yes, there is a clear definition for the expected behavior in the other 
RDBMS.
    
    PS please also notice that Spark currently has a different behavior for 
`select 1 from (select 1) a where (1, 2) not in ((1, null))` and `select 1 from 
(select 1) a where (1, 2) not in (select (1, null))`; while all other RDBMS 
behave in the same way in the two cases.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to