Return-Path: X-Original-To: apmail-hive-dev-archive@www.apache.org Delivered-To: apmail-hive-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8E1F8EDE6 for ; Wed, 16 Jan 2013 16:46:14 +0000 (UTC) Received: (qmail 97709 invoked by uid 500); 16 Jan 2013 16:46:13 -0000 Delivered-To: apmail-hive-dev-archive@hive.apache.org Received: (qmail 97623 invoked by uid 500); 16 Jan 2013 16:46:13 -0000 Mailing-List: contact dev-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hive.apache.org Delivered-To: mailing list dev@hive.apache.org Received: (qmail 97578 invoked by uid 500); 16 Jan 2013 16:46:13 -0000 Delivered-To: apmail-hadoop-hive-dev@hadoop.apache.org Received: (qmail 97564 invoked by uid 99); 16 Jan 2013 16:46:13 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Jan 2013 16:46:13 +0000 Date: Wed, 16 Jan 2013 16:46:12 +0000 (UTC) From: "Ashutosh Chauhan (JIRA)" To: hive-dev@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HIVE-3852) Multi-groupby optimization fails when same distinct column is used twice or more MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/HIVE-3852?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13555191#comment-13555191 ] Ashutosh Chauhan commented on HIVE-3852: ---------------------------------------- Namit, bq. Should we have this optimization now ? I am not sure which particular optimization you are referring to. I assume you mean there is no need for reduce-side groupbys anymore, since we have map-side aggregates. If so, I think those are still required. As Navis, pointed out if reduction ratio is not high enough, mappers may run out of memory and than we suggest users to turn-off map-side aggregation. > Multi-groupby optimization fails when same distinct column is used twice or more > -------------------------------------------------------------------------------- > > Key: HIVE-3852 > URL: https://issues.apache.org/jira/browse/HIVE-3852 > Project: Hive > Issue Type: Bug > Components: Query Processor > Reporter: Navis > Assignee: Navis > Priority: Trivial > Attachments: HIVE-3852.D7737.1.patch > > > {code} > FROM INPUT > INSERT OVERWRITE TABLE dest1 > SELECT INPUT.key, sum(distinct substr(INPUT.value,5)), count(distinct substr(INPUT.value,5)) GROUP BY INPUT.key > INSERT OVERWRITE TABLE dest2 > SELECT INPUT.key, sum(distinct substr(INPUT.value,5)), avg(distinct substr(INPUT.value,5)) GROUP BY INPUT.key; > {code} > fails with exception FAILED: IndexOutOfBoundsException Index: 0,Size: 0 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira