jackwener commented on issue #2254:
URL: 
https://github.com/apache/arrow-datafusion/issues/2254#issuecomment-1101946913

   > I am not at all convinced we do this entirely correctly in the expression 
simplification pass. We should probably have two modes: used in where and used 
elsewhere or something 🤔
   
   Yes, This is where the problem lies. Other optimizer rules depend on 
implicit `not null in where`, which must handle this problem. 
   
   I think we should infer `is not null`, so other rule don't need to do infer 
`not null` but use directly `is not null` inferred by this rewrite. For 
example, convert outer join to left/right outer join or inner join can use `is 
not null` directly instead of match `compare operator`.
   
   


-- 
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]

Reply via email to