-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
[fix](DECIMAL) error DECIMAL cat to BOOLEAN #33868
Conversation
Thank you for your contribution to Apache Doris. Since 2024-03-18, the Document has been moved to doris-website. |
run buildall |
clang-tidy review says "All clean, LGTM! 👍" |
TeamCity be ut coverage result: |
https://dev.mysql.com/doc/refman/8.0/en/cast-functions.html#function_cast cast function of mysql do not support using bool as type argument. |
clang-tidy review says "All clean, LGTM! 👍" |
But there is implicit conversion to boolean. |
run buildall |
why do you think there is an implicit conversion? https://dev.mysql.com/doc/refman/8.3/en/logical-operators.html#operator_and oprator_and checks whether operands are zero or NULL, it has nothing to do with type convert. |
My mistake, as doris implementation involves implicit conversion.
|
I think the problem here may be signature of and operator is not correct, it should not use boolean as operator. |
TeamCity be ut coverage result: |
Proposed changes
before
now
In the past, casting DECIMAL to BOOLEAN directly converted it to an integer.
Further comments
If this is a relatively large or complex change, kick off the discussion at [email protected] by explaining why you chose the solution you did and what alternatives you considered, etc...