Or convert it back to a not-nullable BOOLEAN? The join condition treats UNKNOWN 
the same as FALSE, and besides UNKNOWN will never occur, so the conditions with 
and without the CAST are equivalent. 

Julian

> On Mar 23, 2020, at 9:34 PM, Shuo Cheng <njucs...@gmail.com> wrote:
> 
> Hi all,
> 
> Considering the Join condition 'CAST(IS_NOT_DISTINCT_FROM($1, $2),
> BOOLEAN)', which cast the non-nullable BOOLEAN to nullable BOOLEAN, Calcite
> can not split out equiv predicate, thus some join operation like hash join
> / sort merge join may not be used. Maybe we can
> expand RelOptUtil#splitJoinCondition to support this scenario?

Reply via email to