-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[HUDI-6567] ExpressionEvaluators numeric types conversion support #9230
[HUDI-6567] ExpressionEvaluators numeric types conversion support #9230
Conversation
928ee90
to
fe77d23
Compare
BigDecimal - the most common type of Byte, Short, Integer, Long, Float, Double and BigDecimal |
Can we write some test cases for it. |
7849eb3
to
18dfbfc
Compare
@danny0405 tests are written, pr could be reviewed |
@danny0405 if there are no questions, it could be merged |
void testNotEqualTo() { | ||
@ParameterizedTest | ||
@MethodSource("twelveObjects") | ||
void testNotEqualTo(Object twelve) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we write a separate test for all the data types instead of modifying existing test. We just need to trigger the comparison of different data types. For each of the data type, test the comprison of it to all the other data types.
Just a simple Great Than(GT)
comparision should be enough ~
18dfbfc
to
187d528
Compare
@hudi-bot run azure |
Change Logs
Add numeric types conversion in ExpressionEvaluators::compare method
Impact
For table:
table tbl (a: bigint)
data skipping work only if both types are the same. If we use
select * from tbl where a > 10
data skipping will not work, we have to use explicit cast:
select * from tbl where a > cast(10 as bigint)
this PR fixes it.
See more in HUDI-6567
Risk level (write none, low medium or high below)
none: all conversions are being completed without information lose
Documentation Update
none
Contributor's checklist