You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Julian Hyde (Jira)" <ji...@apache.org> on 2023/04/19 20:16:00 UTC

[jira] [Commented] (CALCITE-5662) Fix CAST(BOOLEAN as INTEGER)

    [ https://issues.apache.org/jira/browse/CALCITE-5662?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17714290#comment-17714290 ] 

Julian Hyde commented on CALCITE-5662:
--------------------------------------

Never start a summary (or commit message) with "fix". Describe the problem.

> Fix CAST(BOOLEAN as INTEGER)
> ----------------------------
>
>                 Key: CALCITE-5662
>                 URL: https://issues.apache.org/jira/browse/CALCITE-5662
>             Project: Calcite
>          Issue Type: Bug
>            Reporter: Oliver Lee
>            Assignee: Oliver Lee
>            Priority: Minor
>
> Currently attempting to run {{SELECT CAST(BOOLEAN as INTEGER)}} will throw a {{NumberFormatException}}.
> The BigQuery dialect allows casting {{boolean}} to {{int64}} and {{string}}, and not for decimal, bigdecimal, numeric, etc. 
> src: https://cloud.google.com/bigquery/docs/reference/standard-sql/conversion_functions 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)