You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by "Hive QA (JIRA)" <ji...@apache.org> on 2013/12/16 23:49:07 UTC
[jira] [Commented] (HIVE-5992) Hive inconsistently converts
timestamp in AVG and SUM UDAF's
[ https://issues.apache.org/jira/browse/HIVE-5992?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13849819#comment-13849819 ]
Hive QA commented on HIVE-5992:
-------------------------------
{color:green}Overall{color}: +1 all checks pass
Here are the results of testing the latest attachment:
https://issues.apache.org/jira/secure/attachment/12618977/HIVE-5992.patch
{color:green}SUCCESS:{color} +1 4789 tests passed
Test results: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/656/testReport
Console output: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/656/console
Messages:
{noformat}
Executing org.apache.hive.ptest.execution.PrepPhase
Executing org.apache.hive.ptest.execution.ExecutionPhase
Executing org.apache.hive.ptest.execution.ReportingPhase
{noformat}
This message is automatically generated.
ATTACHMENT ID: 12618977
> Hive inconsistently converts timestamp in AVG and SUM UDAF's
> ------------------------------------------------------------
>
> Key: HIVE-5992
> URL: https://issues.apache.org/jira/browse/HIVE-5992
> Project: Hive
> Issue Type: Bug
> Components: UDF
> Affects Versions: 0.12.0
> Reporter: Xuefu Zhang
> Assignee: Xuefu Zhang
> Attachments: HIVE-5992.patch
>
>
> {code}
> hive> select t, sum(t), count(*), sum(t)/count(*), avg(t) from ts group by t;
> ...
> OK
> 1977-03-15 12:34:22.345678 227306062 1 227306062 2.27306062345678E8
> {code}
> As it can be seen, timestamp value (1977-03-15 12:34:22.345678) is converted with fractional part ignored in sum, while preserved in avg. As a further result, sum()/count() is not equivalent to avg.
--
This message was sent by Atlassian JIRA
(v6.1.4#6159)