You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by "Murtadha Hubail (JIRA)" <ji...@apache.org> on 2016/05/09 18:47:12 UTC

[jira] [Created] (ASTERIXDB-1430) Unexpected behavior in datetime constructor

Murtadha Hubail created ASTERIXDB-1430:
------------------------------------------

             Summary: Unexpected behavior in datetime constructor
                 Key: ASTERIXDB-1430
                 URL: https://issues.apache.org/jira/browse/ASTERIXDB-1430
             Project: Apache AsterixDB
          Issue Type: Bug
          Components: Functions - AQL
            Reporter: Murtadha Hubail


I used the function adjust-datetime-for-timezone(datetime, zone), which returns string type, to adjust the current datetime, then I wanted to use the returned value as datetime type.

When I tried the following:
{noformat}
let $adjustedDatetime := adjust-datetime-for-timezone(current-datetime(), "-10:00")

return datetime($adjustedDatetime)
{noformat}

The returned datetime value lost the adjustment.

I think the datetime constructor should either respect the adjustment or throw an invalid format exception.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)