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 AA2E9E411 for ; Sun, 20 Jan 2013 07:12:14 +0000 (UTC) Received: (qmail 82069 invoked by uid 500); 20 Jan 2013 07:12:14 -0000 Delivered-To: apmail-hive-dev-archive@hive.apache.org Received: (qmail 82014 invoked by uid 500); 20 Jan 2013 07:12: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 82001 invoked by uid 500); 20 Jan 2013 07:12:13 -0000 Delivered-To: apmail-hadoop-hive-dev@hadoop.apache.org Received: (qmail 81985 invoked by uid 99); 20 Jan 2013 07:12:13 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 20 Jan 2013 07:12:13 +0000 Date: Sun, 20 Jan 2013 07:12:12 +0000 (UTC) From: "Ashutosh Chauhan (JIRA)" To: hive-dev@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HIVE-2332) If all of the parameters of distinct functions are exists in group by columns, query fails in runtime 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-2332?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ashutosh Chauhan updated HIVE-2332: ----------------------------------- Resolution: Fixed Fix Version/s: 0.11.0 Status: Resolved (was: Patch Available) Committed to trunk. Thanks, Navis! > If all of the parameters of distinct functions are exists in group by columns, query fails in runtime > ----------------------------------------------------------------------------------------------------- > > Key: HIVE-2332 > URL: https://issues.apache.org/jira/browse/HIVE-2332 > Project: Hive > Issue Type: Bug > Components: Query Processor > Affects Versions: 0.9.0 > Reporter: Navis > Assignee: Navis > Priority: Blocker > Fix For: 0.11.0 > > Attachments: ASF.LICENSE.NOT.GRANTED--HIVE-2332.D663.1.patch, HIVE-2332.1.patch.txt, HIVE-2332.2.patch.txt > > > select sum(key_int1), sum(distinct key_int1) from t1 group by key_int1; > fails with message.. > {code} > FAILED: Execution Error, return code 2 from org.apache.hadoop.hive.ql.exec.MapRedTask > {code} > hadoop says.. > {code} > Caused by: java.lang.IndexOutOfBoundsException: Index: 1, Size: 1 > at java.util.ArrayList.RangeCheck(ArrayList.java:547) > at java.util.ArrayList.get(ArrayList.java:322) > at org.apache.hadoop.hive.serde2.objectinspector.StandardStructObjectInspector.init(StandardStructObjectInspector.java:95) > at org.apache.hadoop.hive.serde2.objectinspector.StandardStructObjectInspector.(StandardStructObjectInspector.java:86) > at org.apache.hadoop.hive.serde2.objectinspector.ObjectInspectorFactory.getStandardStructObjectInspector(ObjectInspectorFactory.java:252) > at org.apache.hadoop.hive.ql.exec.ReduceSinkOperator.initEvaluatorsAndReturnStruct(ReduceSinkOperator.java:188) > at org.apache.hadoop.hive.ql.exec.ReduceSinkOperator.processOp(ReduceSinkOperator.java:197) > at org.apache.hadoop.hive.ql.exec.Operator.process(Operator.java:471) > at org.apache.hadoop.hive.ql.exec.Operator.forward(Operator.java:744) > at org.apache.hadoop.hive.ql.exec.TableScanOperator.processOp(TableScanOperator.java:85) > at org.apache.hadoop.hive.ql.exec.Operator.process(Operator.java:471) > at org.apache.hadoop.hive.ql.exec.Operator.forward(Operator.java:744) > at org.apache.hadoop.hive.ql.exec.MapOperator.process(MapOperator.java:532) > {code} > I think the deficient number of key expression, compared to number of key column, is the problem, which should be equal or more. > Would it be solved if add some key expression? I'll try. -- 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