You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@impala.apache.org by "Michael Brown (JIRA)" <ji...@apache.org> on 2017/08/24 16:23:00 UTC
[jira] [Resolved] (IMPALA-5348) remove mention of stringized
timestamp literals with interval expressions
[ https://issues.apache.org/jira/browse/IMPALA-5348?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Michael Brown resolved IMPALA-5348.
-----------------------------------
Resolution: Fixed
Fix Version/s: Impala 2.9.0
https://gerrit.cloudera.org/#/c/7067/
> remove mention of stringized timestamp literals with interval expressions
> -------------------------------------------------------------------------
>
> Key: IMPALA-5348
> URL: https://issues.apache.org/jira/browse/IMPALA-5348
> Project: IMPALA
> Issue Type: Bug
> Components: Docs
> Affects Versions: Impala 2.9.0
> Reporter: Michael Brown
> Assignee: John Russell
> Fix For: Impala 2.9.0
>
>
> http://impala.apache.org/docs/build/html/topics/impala_literals.html mentions being able to apply {{INTERVAL}} expressions to strings that will be able to be coerced as timestamps,
> bq. You can also use INTERVAL expressions to add or subtract from timestamp literal values, such as '1966-07-30' + INTERVAL 5 YEARS + INTERVAL 3 DAYS.
> but a user pointed out on dev@ that this is wrong:
> {noformat}
> [localhost:21000] > SELECT '1966-07-30' + INTERVAL 1 YEAR;
> ERROR: AnalysisException: Operand ''1966-07-30'' of timestamp arithmetic expression ''1966-07-30' + INTERVAL 1 YEAR' returns type 'STRING'. Expected type 'TIMESTAMP'.
> [localhost:21000] >
> {noformat}
> Documentation should be altered to fix this.
> It looks like [~jrussell] pointed this out in IMPALA-2293, which was marked as a dupe of IMPALA-1503.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)