Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 0E02B200D3A for ; Wed, 15 Nov 2017 11:19:06 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 0BF6B160BF4; Wed, 15 Nov 2017 10:19:06 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 52170160BEA for ; Wed, 15 Nov 2017 11:19:05 +0100 (CET) Received: (qmail 2936 invoked by uid 500); 15 Nov 2017 10:19:04 -0000 Mailing-List: contact issues-help@carbondata.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@carbondata.apache.org Delivered-To: mailing list issues@carbondata.apache.org Received: (qmail 2927 invoked by uid 99); 15 Nov 2017 10:19:04 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 15 Nov 2017 10:19:04 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id A76861A1C65 for ; Wed, 15 Nov 2017 10:19:03 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.202 X-Spam-Level: X-Spam-Status: No, score=-99.202 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id dMcos2Y0tHRu for ; Wed, 15 Nov 2017 10:19:02 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id B2A6B60F71 for ; Wed, 15 Nov 2017 10:19:01 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 7E273E0E56 for ; Wed, 15 Nov 2017 10:19:00 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 26E0A240D2 for ; Wed, 15 Nov 2017 10:19:00 +0000 (UTC) Date: Wed, 15 Nov 2017 10:19:00 +0000 (UTC) From: "Ramakrishna S (JIRA)" To: issues@carbondata.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (CARBONDATA-1719) Carbon1.3.0-Pre-AggregateTable - Empty segment is created if pre-aggr table created in parallel with table load, aggregate query returns no data MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 15 Nov 2017 10:19:06 -0000 Ramakrishna S created CARBONDATA-1719: ----------------------------------------- Summary: Carbon1.3.0-Pre-AggregateTable - Empty segment is created if pre-aggr table created in parallel with table load, aggregate query returns no data Key: CARBONDATA-1719 URL: https://issues.apache.org/jira/browse/CARBONDATA-1719 Project: CarbonData Issue Type: Bug Components: data-load Affects Versions: 1.3.0 Environment: Test - 3 node ant cluster Reporter: Ramakrishna S Fix For: 1.3.0 1. Create a table create table if not exists lineitem3(L_SHIPDATE string,L_SHIPMODE string,L_SHIPINSTRUCT string,L_RETURNFLAG string,L_RECEIPTDATE string,L_ORDERKEY string,L_PARTKEY string,L_SUPPKEY string,L_LINENUMBER int,L_QUANTITY double,L_EXTENDEDPRICE double,L_DISCOUNT double,L_TAX double,L_LINESTATUS string,L_COMMITDATE string,L_COMMENT string) STORED BY 'org.apache.carbondata.format' TBLPROPERTIES ('table_blocksize'='128','NO_INVERTED_INDEX'='L_SHIPDATE,L_SHIPMODE,L_SHIPINSTRUCT,L_RETURNFLAG,L_RECEIPTDATE,L_ORDERKEY,L_PARTKEY,L_SUPPKEY','sort_columns'=''); 2. Run load queries and create pre-agg table queries in diff console: load data inpath "hdfs://hacluster/user/test/lineitem.tbl.1" into table lineitem3 options('DELIMITER'='|','FILEHEADER'='L_ORDERKEY,L_PARTKEY,L_SUPPKEY,L_LINENUMBER,L_QUANTITY,L_EXTENDEDPRICE,L_DISCOUNT,L_TAX,L_RETURNFLAG,L_LINESTATUS,L_SHIPDATE,L_COMMITDATE,L_RECEIPTDATE,L_SHIPINSTRUCT,L_SHIPMODE,L_COMMENT'); create datamap agr_lineitem3 ON TABLE lineitem3 USING "org.apache.carbondata.datamap.AggregateDataMapHandler" as select L_RETURNFLAG,L_LINESTATUS,sum(L_QUANTITY),sum(L_EXTENDEDPRICE) from lineitem3 group by L_RETURNFLAG, L_LINESTATUS; 3. Check table content using aggregate query: select l_returnflag,l_linestatus,sum(l_quantity),sum(l_extendedprice) from lineitem3 group by l_returnflag, l_linestatus; 0: jdbc:hive2://10.18.98.34:23040> show segments for table lineitem2; +--------------------+----------+--------------------------+--------------------------+------------+--+ | SegmentSequenceId | Status | Load Start Time | Load End Time | Merged To | +--------------------+----------+--------------------------+--------------------------+------------+--+ | 0 | Success | 2017-11-15 17:56:54.554 | 2017-11-15 17:57:56.605 | | +--------------------+----------+--------------------------+--------------------------+------------+--+ 1 row selected (0.179 seconds) 0: jdbc:hive2://10.18.98.34:23040> show segments for table lineitem1; HDFS data: BLR1000014307:/srv/spark2.2Bigdata/install/hadoop/datanode # bin/hadoop fs -ls /carbonstore/default/lineitem3_agr_lineitem3/Fact/Part0/Segment_0 17/11/15 18:15:18 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable BLR1000014307:/srv/spark2.2Bigdata/install/hadoop/datanode # bin/hadoop fs -ls /carbonstore/default/lineitem3/Fact/Part0/Segment_0 17/11/15 18:15:34 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable Found 27 items -rw-r--r-- 2 root users 22148 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/1510740293106.carbonindexmerge -rw-r--r-- 2 root users 58353052 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/part-0-0_batchno0-0-1510740300247.carbondata -rw-r--r-- 2 root users 58351680 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/part-0-0_batchno1-0-1510740300247.carbondata -rw-r--r-- 2 root users 58364823 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/part-0-1_batchno0-0-1510740300247.carbondata -rw-r--r-- 2 root users 58356303 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/part-0-2_batchno0-0-1510740300247.carbondata -rw-r--r-- 2 root users 58342246 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/part-1-0_batchno0-0-1510740300247.carbondata -rw-r--r-- 2 root users 58353186 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/part-1-0_batchno1-0-1510740300247.carbondata -rw-r--r-- 2 root users 58352964 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/part-1-1_batchno0-0-1510740300247.carbondata -rw-r--r-- 2 root users 58357183 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/part-1-2_batchno0-0-1510740300247.carbondata -rw-r--r-- 2 root users 58345739 2017-11-15 18:05 /carbonstore/default/lineitem3/Fact/Part0/Segment_0/part-2-0_batchno0-0-1510740300247.carbondata Yarn job stages: -- This message was sent by Atlassian JIRA (v6.4.14#64029)