You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "Tim Armstrong (Jira)" <ji...@apache.org> on 2020/08/13 21:09:00 UTC
[jira] [Resolved] (IMPALA-2543) Typo in timestamp value produces
corrupt result instead of an error
[ https://issues.apache.org/jira/browse/IMPALA-2543?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tim Armstrong resolved IMPALA-2543.
-----------------------------------
Resolution: Cannot Reproduce
This is fixed on master now. I'm not sure what patch fixed it - maybe IMPALA-5315
> Typo in timestamp value produces corrupt result instead of an error
> -------------------------------------------------------------------
>
> Key: IMPALA-2543
> URL: https://issues.apache.org/jira/browse/IMPALA-2543
> Project: IMPALA
> Issue Type: Bug
> Components: Backend
> Affects Versions: Impala 2.3.0
> Reporter: Ryan Blue
> Priority: Major
> Labels: correctness, timestamp, usability
>
> Running timestamp tests, I hit the following bug where a typo in a timestamp string produced a strange result without complaining that the input value was invalid:
> {code}
> Query: select to_utc_timestamp('2015-10-13-09:15:34.101', 'PDT')
> Oops. -----------------------------------^
> +----------------------------------------------------+
> | to_utc_timestamp('2015-10-13-09:15:34.101', 'pdt') |
> +----------------------------------------------------+
> | 2015-10-13 07:00:00 | // ???
> +----------------------------------------------------+
> Query: select to_utc_timestamp('2015-10-13 09:15:34.101', 'PDT')
> +----------------------------------------------------+
> | to_utc_timestamp('2015-10-13 09:15:34.101', 'pdt') |
> +----------------------------------------------------+
> | 2015-10-13 16:15:34.101000000 | // MUCH BETTER
> +----------------------------------------------------+
> {code}
> It looks like anything after the bad character is ignored:
> {code}
> Query: select to_utc_timestamp('2015-10-13-09:15:34.101', 'UTC')
> +----------------------------------------------------+
> | to_utc_timestamp('2015-10-13-09:15:34.101', 'utc') |
> +----------------------------------------------------+
> | 2015-10-13 00:00:00 |
> +----------------------------------------------------+
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org