Return-Path: X-Original-To: apmail-hive-issues-archive@minotaur.apache.org Delivered-To: apmail-hive-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7F79F17557 for ; Tue, 9 Jun 2015 09:58:01 +0000 (UTC) Received: (qmail 95203 invoked by uid 500); 9 Jun 2015 09:58:00 -0000 Delivered-To: apmail-hive-issues-archive@hive.apache.org Received: (qmail 95085 invoked by uid 500); 9 Jun 2015 09:58:00 -0000 Mailing-List: contact issues-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 issues@hive.apache.org Received: (qmail 94833 invoked by uid 99); 9 Jun 2015 09:58:00 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 09 Jun 2015 09:58:00 +0000 Date: Tue, 9 Jun 2015 09:58:00 +0000 (UTC) From: "wangmeng (JIRA)" To: issues@hive.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HIVE-10971) count(*) with count(distinct) gives wrong results when hive.groupby.skewindata=true 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-10971?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] wangmeng updated HIVE-10971: ---------------------------- Component/s: (was: Hive) Logical Optimizer > count(*) with count(distinct) gives wrong results when hive.groupby.skewindata=true > ----------------------------------------------------------------------------------- > > Key: HIVE-10971 > URL: https://issues.apache.org/jira/browse/HIVE-10971 > Project: Hive > Issue Type: Bug > Components: Logical Optimizer > Affects Versions: 1.2.0 > Reporter: wangmeng > Assignee: wangmeng > > When hive.groupby.skewindata=true, the following query based on TPC-H gives wrong results: > {code} > set hive.groupby.skewindata=true; > select l_returnflag, count(*), count(distinct l_linestatus) > from lineitem > group by l_returnflag > limit 10; > {code} > The query plan shows that it generates only one MapReduce job instead of two theoretically, which is dictated by hive.groupby.skewindata=true. > The problem arises only when {noformat}count(*){noformat} and {noformat}count(distinct){noformat} exist together. -- This message was sent by Atlassian JIRA (v6.3.4#6332)