You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@tajo.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2016/04/04 11:00:35 UTC

[jira] [Commented] (TAJO-2110) Fix incorrect DateTime and remove hard coded tests

    [ https://issues.apache.org/jira/browse/TAJO-2110?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15223844#comment-15223844 ] 

ASF GitHub Bot commented on TAJO-2110:
--------------------------------------

GitHub user jinossy opened a pull request:

    https://github.com/apache/tajo/pull/993

    TAJO-2110: Fix incorrect DateTime and remove hard coded tests.

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/jinossy/tajo TAJO-2110

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/tajo/pull/993.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #993
    
----
commit 6f3d71c4cff95ffe1a7d14804c85baaf11606f81
Author: Jinho Kim <jh...@apache.org>
Date:   2016-04-04T08:58:16Z

    TAJO-2110: Fix incorrect DateTime and remove hard coded tests.

----


> Fix incorrect DateTime and remove hard coded tests
> --------------------------------------------------
>
>                 Key: TAJO-2110
>                 URL: https://issues.apache.org/jira/browse/TAJO-2110
>             Project: Tajo
>          Issue Type: Bug
>          Components: Data Type, Storage, Unit Test
>    Affects Versions: 0.12.0
>            Reporter: Jinho Kim
>            Assignee: Jinho Kim
>            Priority: Critical
>
> Currently, Most DateTime tests are not work correctly. because timezone is hardcode to the GMT for testing.
> if you run CTAS, the result data will be incorrect. we should remove the hardcoded timezone in TajoTestingCluster
> Here is some examples:
> Example 1
> {noformat}
> if you run CTAS, the result data will be incorrect
> default> create table test1 (col1 TIMESTAMP);
> default> insert overwrite into test1 select '2016-04-04 00:00:00'::TIMESTAMP;
> default> select * from test1;
> col1
> -------------------------------
> 2016-04-04 00:00:00
> (1 rows, 0.057 sec, 0 B selected)
> default> create table test2 as select * from test1;
> [=========================================>] 100%  0.105 sec
> (1 rows, 0.105 sec, 20 B inserted)
> default> select * from test2;
> col1
> -------------------------------
> 2016-04-03 15:00:00
> {noformat}
> Example 2
> {noformat}
> default> select '2016-04-04 01:00:00'::TIMESTAMP - interval '1 hour';
> ?minus
> -------------------------------
> 2016-04-04 09:00:00
> (1 rows, 0.005 sec, 0 B selected)
> {noformat}



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