-
Notifications
You must be signed in to change notification settings - Fork 26
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
Loading a Bool-datatype column #94
Comments
Clickhouse does not support a dedicated Boolean type. It is basically an alias for UInt8 such that a direct translation could lead to unexpected behavior. See https://content.clickhouse.tech/docs/en/sql-reference/data-types/boolean/ for more details. |
Here is the documentation, a click for some reason leads both sites at the same time: https://clickhouse.com/docs/en/sql-reference/data-types/boolean Please open the task and add the data type |
I'll split my response into a (1) more or less emotional general and a (2) hopefully objective and constructive issue-related part: 1) Let's start with the general.
2) Now to the actual topic. ClickHouse is developing rapidly. I am not always up to date; sometimes, the documentation is outdated. Therefore, we may make decisions based on wrong information. Indeed, casting bool as logical makes sense if there is a dedicated boolean type (not an alias for UInt8 as it used to be). We'll look at this again and may extend it accordingly. However, if you need this function badly, feel free to provide a pull request (this is the great part of free software). Meanwhile, you can use UInt8 to load the data and manually convert it to Logical. This is not ideal, but should be doable and sufficient for now. |
Please register the
Bool
-datatype when loading the dataset in the form oflogical
-classThe text was updated successfully, but these errors were encountered: