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 5451817C40 for ; Tue, 10 Feb 2015 07:31:37 +0000 (UTC) Received: (qmail 6106 invoked by uid 500); 10 Feb 2015 07:31:37 -0000 Delivered-To: apmail-hive-dev-archive@hive.apache.org Received: (qmail 6034 invoked by uid 500); 10 Feb 2015 07:31:37 -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 6023 invoked by uid 500); 10 Feb 2015 07:31:36 -0000 Delivered-To: apmail-hadoop-hive-dev@hadoop.apache.org Received: (qmail 6020 invoked by uid 99); 10 Feb 2015 07:31:36 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 10 Feb 2015 07:31:36 +0000 Date: Tue, 10 Feb 2015 07:31:36 +0000 (UTC) From: "Ashutosh Chauhan (JIRA)" To: hive-dev@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HIVE-9618) Deduplicate RS keys for ptf/windowing 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-9618?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14313745#comment-14313745 ] Ashutosh Chauhan commented on HIVE-9618: ---------------------------------------- +1 > Deduplicate RS keys for ptf/windowing > ------------------------------------- > > Key: HIVE-9618 > URL: https://issues.apache.org/jira/browse/HIVE-9618 > Project: Hive > Issue Type: Improvement > Components: PTF-Windowing > Reporter: Navis > Assignee: Navis > Priority: Trivial > Attachments: HIVE-9618.1.patch.txt, HIVE-9618.2.patch.txt > > > Currently, partition spec containing same column for partition-by and order-by makes duplicated key column for RS. For example, > {noformat} > explain > select p_mfgr, p_name, p_size, > rank() over (partition by p_mfgr order by p_name) as r, > dense_rank() over (partition by p_mfgr order by p_name) as dr, > sum(p_retailprice) over (partition by p_mfgr order by p_name rows between unbounded preceding and current row) as s1 > from noop(on noopwithmap(on noop(on part > partition by p_mfgr > order by p_mfgr, p_name > ))) > {noformat} > "partition by p_mfgr order by p_mfgr, p_name" makes duplicated key columns like below > {noformat} > Reduce Output Operator > key expressions: p_mfgr (type: string), p_mfgr (type: string), p_name (type: string) > sort order: +++ > Map-reduce partition columns: p_mfgr (type: string) > value expressions: p_size (type: int), p_retailprice (type: double) > {noformat} -- This message was sent by Atlassian JIRA (v6.3.4#6332)