Return-Path: Delivered-To: apmail-hadoop-hive-dev-archive@locus.apache.org Received: (qmail 60720 invoked from network); 11 Jan 2009 02:46:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 11 Jan 2009 02:46:22 -0000 Received: (qmail 16265 invoked by uid 500); 11 Jan 2009 02:46:22 -0000 Delivered-To: apmail-hadoop-hive-dev-archive@hadoop.apache.org Received: (qmail 16238 invoked by uid 500); 11 Jan 2009 02:46:22 -0000 Mailing-List: contact hive-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hive-dev@hadoop.apache.org Delivered-To: mailing list hive-dev@hadoop.apache.org Received: (qmail 16227 invoked by uid 99); 11 Jan 2009 02:46:22 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 10 Jan 2009 18:46:22 -0800 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 11 Jan 2009 02:46:20 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id AFAAF234C4A7 for ; Sat, 10 Jan 2009 18:45:59 -0800 (PST) Message-ID: <1194855315.1231641959718.JavaMail.jira@brutus> Date: Sat, 10 Jan 2009 18:45:59 -0800 (PST) From: "Prasad Chakka (JIRA)" To: hive-dev@hadoop.apache.org Subject: [jira] Updated: (HIVE-25) [Hive] cluster by does not work with column aliasing MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HIVE-25?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Prasad Chakka updated HIVE-25: ------------------------------ Attachment: hive-25-code-changes.patch Attached is the proposed code changes. Fix for this seems to be more complex that I originally thought. This fix will work for below type of queries. The fix attempts to make all column references with in a parenthesis refer to tables specified in the from clause. SELECT x.* FROM SRC x CLUSTER BY x.key; SELECT y.* from (SELECT x.* FROM SRC x CLUSTER BY key) y where y.key = 20; SELECT y.* from (SELECT x.* FROM SRC x CLUSTER BY x.key) y where y.key = 20; Would appreciate your thoughts on this. > [Hive] cluster by does not work with column aliasing > ---------------------------------------------------- > > Key: HIVE-25 > URL: https://issues.apache.org/jira/browse/HIVE-25 > Project: Hadoop Hive > Issue Type: Bug > Components: Query Processor > Reporter: Namit Jain > Assignee: Prasad Chakka > Priority: Critical > Attachments: hive-25-code-changes.patch > > > SELECT b.* > FROM > ( > SELECT x.col1, x.col2 > FROM tmp x > WHERE x.col2= 10 > CLUSTER BY col2 > ) b" > The above query works, but if I change the cluster by to: > CLUSTER BY x.col2, > it croaks. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.