tajo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hyunsik Choi (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (TAJO-417) TestSQLExpression.testCastFromTable causes unit test failure
Date Sat, 14 Dec 2013 11:11:07 GMT

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

Hyunsik Choi commented on TAJO-417:
-----------------------------------

This problem causes the current jenkins test failures.
https://builds.apache.org/job/Tajo-trunk-postcommit/617/testReport/org.apache.tajo.engine.eval/TestSQLExpression/testCastFromTable/

> TestSQLExpression.testCastFromTable causes unit test failure
> ------------------------------------------------------------
>
>                 Key: TAJO-417
>                 URL: https://issues.apache.org/jira/browse/TAJO-417
>             Project: Tajo
>          Issue Type: Bug
>          Components: operator/expression
>            Reporter: Hyunsik Choi
>            Assignee: Hyunsik Choi
>            Priority: Trivial
>             Fix For: 0.8-incubating
>
>         Attachments: TAJO-417.patch
>
>
> {code}
> testSimpleEval("select '1980-04-01 01:50:01'::timestamp::bigint;", new String [] {"323369401000"});
>     testSimpleEval("select ('1980-04-01 01:50:01'::timestamp)::bigint;", new String []
{"323369401000"});
> {code}
> The above unit tests can cause failure due to the precision difference between bigint
value and the value casted from timestamp string. This patch eliminates the difference by
using only timestamp strings.
> {code}
> testSimpleEval("select '1980-04-01 01:50:01'::timestamp::bigint::timestamp", new String
[] {"1980-04-01 01:50:01"});
>     testSimpleEval("select cast (('1980-04-01 01:50:01'::timestamp)::bigint as timestamp)",
>         new String [] {"1980-04-01 01:50:01"});
> {code}



--
This message was sent by Atlassian JIRA
(v6.1.4#6159)

Mime
View raw message