Github user mgaido91 commented on a diff in the pull request:

    https://github.com/apache/spark/pull/21403#discussion_r207805905
  
    --- Diff: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/optimizer/expressions.scala
 ---
    @@ -505,6 +505,7 @@ object NullPropagation extends Rule[LogicalPlan] {
     
           // If the value expression is NULL then transform the In expression 
to null literal.
           case In(Literal(null, _), _) => Literal.create(null, BooleanType)
    +      case InSubquery(Seq(Literal(null, _)), _) => Literal.create(null, 
BooleanType)
    --- End diff --
    
    Thanks for your comment. I checked it again and I am pretty sure no 
regression is introduced. We don't have many optimizer rules using In and all 
the others were and are applied only to In with a list of literals. I am adding 
this and the other tests. Thanks.


---

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

Reply via email to