[
https://issues.apache.org/jira/browse/DRILL-3971?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Kristine Hahn resolved DRILL-3971.
----------------------------------
Resolution: Fixed
> to_date(timestamp) is supported
> --------------------------------
>
> Key: DRILL-3971
> URL: https://issues.apache.org/jira/browse/DRILL-3971
> Project: Apache Drill
> Issue Type: Task
> Components: Documentation
> Reporter: Sean Hsuan-Yi Chu
> Assignee: Kristine Hahn
>
> Do a search for "to_date" in this link:
> https://drill.apache.org/docs/data-type-conversion/
> We would find that it says these two are supported:
> 1. expression is a character string enclosed... (rest is omitted)
> 2. 'format' is a format specifier enclosed... (rest is omitted)
> Due to DRILL-3769, let's add one more supported case: expression can be
> timp_stamp type.
> A example would be:
> {code}
> 0: jdbc:drill:zk=local> select to_date(to_timestamp(1000000000)) from
> (VALUES(1));
> +-------------+
> | EXPR$0 |
> +-------------+
> | 2001-09-09 |
> +-------------+
> {code}
> Note that to_timestamp(1000000000) would generate a timestamp with value
> 2001-09-08 18:46:40.0 (on MAC, which can be different on Linux )
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)