Skip to content

Commit

Permalink
KE-37052 translate boolean column to V2Predicate (apache#477)
Browse files Browse the repository at this point in the history
  • Loading branch information
chenzhx authored Jun 7, 2022
1 parent 0553594 commit 7796f19
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,12 @@ class V2ExpressionBuilder(
} else {
Some(FieldReference(name))
}
case pushableColumn(name) if !nestedPredicatePushdownEnabled =>
Some(FieldReference(name))
case col @ pushableColumn(name) if !nestedPredicatePushdownEnabled =>
if (isPredicate && col.dataType.isInstanceOf[BooleanType]) {
Some(new V2Predicate("=", Array(FieldReference(name), LiteralValue(true, BooleanType))))
} else {
Some(FieldReference(name))
}
case in @ InSet(child, hset) =>
generateExpression(child).map { v =>
val children =
Expand Down

0 comments on commit 7796f19

Please sign in to comment.