You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Mehant Baid (JIRA)" <ji...@apache.org> on 2014/06/10 08:33:01 UTC

[jira] [Resolved] (DRILL-596) cast interval as interval day failed

     [ https://issues.apache.org/jira/browse/DRILL-596?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mehant Baid resolved DRILL-596.
-------------------------------

    Resolution: Invalid

Please use the ISO 8601 format to be able to cast from varchar to interval data types. 

> cast interval as interval day failed
> ------------------------------------
>
>                 Key: DRILL-596
>                 URL: https://issues.apache.org/jira/browse/DRILL-596
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Functions - Drill
>            Reporter: Chun Chang
>            Assignee: Mehant Baid
>
> Here is postgres result:
> foodmart=# select c_row, c_interval, cast(c_interval as interval day) from data where c_row = 1;
>  c_row | c_interval | c_interval
> -------+------------+------------
>      1 | 00:01:00   | 00:00:00
> (1 row)
> Drill fail with the following error:
> 0: jdbc:drill:schema=dfs> select c_row, cast(c_interval as interval day) from data where c_row = 1;
> Query failed: org.apache.drill.exec.rpc.RpcException: Remote failure while running query.[error_id: "8aba37e6-1744-4dc4-83f4-53abf5bf3fd5"
> endpoint {
>   address: "qa-node119.qa.lab"
>   user_port: 31010
>   control_port: 31011
>   data_port: 31012
> }
> error_type: 0
> message: "Failure while running fragment. < IllegalArgumentException:[ Invalid format: \"00:01:00\" ]"
> ]
> Error: exception while executing query (state=,code=0)



--
This message was sent by Atlassian JIRA
(v6.2#6252)