liukun4515 commented on code in PR #3301:
URL: https://github.com/apache/arrow-datafusion/pull/3301#discussion_r959303031
##########
datafusion/physical-expr/src/planner.rs:
##########
@@ -83,6 +83,84 @@ pub fn create_physical_expr(
}
}
}
+ Expr::IsTrue(expr) => {
+ let binary_op = binary_expr(
+ expr.as_ref().clone(),
+ Operator::IsNotDistinctFrom,
+ Expr::Literal(ScalarValue::Boolean(Some(true))),
+ );
+ create_physical_expr(
+ &binary_op,
+ input_dfschema,
+ input_schema,
+ execution_props,
+ )
+ }
+ Expr::IsNotTrue(expr) => {
+ let binary_op = binary_expr(
+ expr.as_ref().clone(),
+ Operator::IsDistinctFrom,
+ Expr::Literal(ScalarValue::Boolean(Some(true))),
+ );
+ create_physical_expr(
+ &binary_op,
+ input_dfschema,
+ input_schema,
+ execution_props,
+ )
+ }
+ Expr::IsFalse(expr) => {
+ let binary_op = binary_expr(
+ expr.as_ref().clone(),
+ Operator::IsNotDistinctFrom,
+ Expr::Literal(ScalarValue::Boolean(Some(false))),
+ );
+ create_physical_expr(
+ &binary_op,
+ input_dfschema,
+ input_schema,
+ execution_props,
+ )
+ }
+ Expr::IsNotFalse(expr) => {
+ let binary_op = binary_expr(
+ expr.as_ref().clone(),
+ Operator::IsDistinctFrom,
+ Expr::Literal(ScalarValue::Boolean(Some(false))),
+ );
+ create_physical_expr(
+ &binary_op,
+ input_dfschema,
+ input_schema,
+ execution_props,
+ )
+ }
+ Expr::IsUnknown(expr) => {
Review Comment:
I have checked the Op in the PG:
https://www.postgresql.org/docs/current/functions-comparison.html
The data type of `is true, is false..., is unknown...` must be bool type.
--
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]