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 4ACE3957C for ; Thu, 26 Jan 2012 16:35:03 +0000 (UTC) Received: (qmail 17862 invoked by uid 500); 26 Jan 2012 16:35:02 -0000 Delivered-To: apmail-hive-dev-archive@hive.apache.org Received: (qmail 17461 invoked by uid 500); 26 Jan 2012 16:35:02 -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 17453 invoked by uid 500); 26 Jan 2012 16:35:01 -0000 Delivered-To: apmail-hadoop-hive-dev@hadoop.apache.org Received: (qmail 17450 invoked by uid 99); 26 Jan 2012 16:35:01 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 Jan 2012 16:35:01 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 Jan 2012 16:34:59 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id A7E83164D34 for ; Thu, 26 Jan 2012 16:34:38 +0000 (UTC) Date: Thu, 26 Jan 2012 16:34:38 +0000 (UTC) From: "Hudson (Commented) (JIRA)" To: hive-dev@hadoop.apache.org Message-ID: <448480424.81852.1327595678689.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <561475059.79177.1327543780689.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (HIVE-2750) Hive multi group by single reducer optimization causes invalid column reference error MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HIVE-2750?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13193949#comment-13193949 ] Hudson commented on HIVE-2750: ------------------------------ Integrated in Hive-trunk-h0.21 #1222 (See [https://builds.apache.org/job/Hive-trunk-h0.21/1222/]) HIVE-2750 Hive multi group by single reducer optimization causes invalid column reference error (Kevin Wilfong via namit) namit : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1236150 Files : * /hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java * /hive/trunk/ql/src/test/queries/clientpositive/groupby_multi_single_reducer2.q * /hive/trunk/ql/src/test/results/clientpositive/groupby_multi_single_reducer2.q.out > Hive multi group by single reducer optimization causes invalid column reference error > ------------------------------------------------------------------------------------- > > Key: HIVE-2750 > URL: https://issues.apache.org/jira/browse/HIVE-2750 > Project: Hive > Issue Type: Bug > Reporter: Kevin Wilfong > Assignee: Kevin Wilfong > Attachments: HIVE-2750.D1455.1.patch > > > After the optimization, if two query blocks have the same distinct clause and the same group by keys, but the first query block does not reference all the rows the second query block does, an invalid column reference error is raised for the columns unreferenced in the first query block. > E.g. > FROM src > INSERT OVERWRITE TABLE dest_g2 SELECT substr(src.key,1,1), count(DISTINCT src.key) WHERE substr(src.key,1,1) >= 5 GROUP BY substr(src.key,1,1) > INSERT OVERWRITE TABLE dest_g3 SELECT substr(src.key,1,1), count(DISTINCT src.key), count(src.value) WHERE substr(src.key,1,1) < 5 GROUP BY substr(src.key,1,1); > This results in an invalid column reference error on src.value -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira