-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Support import true or false as boolean value #3898
Conversation
@yangzhg Hi, I think the result of processing bool value for stream load and insert stmt should keep consistent. |
@chaoyli Insert into xx values("0") and stream load import file 0 is not consistent in the current code. Insert into xx values("0") result=true, stream load 0 result=false, and now cast_to_bool Only occurs when the type of the column is bool, so it is not contradictory to the current insert |
I think the meaning of caiconghui is to make consistent of stream load and insert in any situation. |
@caiconghui I will change the insert statement and stream load to keep consistent with mysql |
d3ad424
to
2a15dff
Compare
Fixes #3831
After this PR
insert into:
1/"1" -> 1, 0/"0"->0, true/"true"->1, false/"false" -> 0, "10"->null, "xxxx" -> null
load:
1/true -> 1, 0/false -> 0, other -> null