You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@impala.apache.org by "Jozsef Koza (Jira)" <ji...@apache.org> on 2020/01/08 13:30:00 UTC

[jira] [Created] (IMPALA-9280) Time string with signed TZH token and dash separator cannot be cast to timestamp

Jozsef Koza created IMPALA-9280:
-----------------------------------

             Summary: Time string with signed TZH token and dash separator cannot be cast to timestamp
                 Key: IMPALA-9280
                 URL: https://issues.apache.org/jira/browse/IMPALA-9280
             Project: IMPALA
          Issue Type: Bug
          Components: Backend
    Affects Versions: Impala 3.3.0
            Reporter: Jozsef Koza


Given a time string containing a TZH token with a sign which is preceded immediately by a dash delimiter cannot be cast to timestamp.

h3. To reproduce

Execute {code:sql}
select cast("08:00-+01" as timestamp format "HH:MI-TZH");{code} which results in *NULL*.

 
----

It seems like the delimiter is incorrectly recognised as the sign of the timezone offset hour which prevents parsing the TZH value.
 Adding an additional delimiter (other than dash itself) between the dash separator and the sign in the time string makes cast working.

Executing
{code:sql}
select cast("08:00- +01" as timestamp format "HH:MI-TZH");{code}
results in *08:00:00*.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)