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 14664200C1B for ; Tue, 14 Feb 2017 15:36:32 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 0E7AB160B5F; Tue, 14 Feb 2017 14:36:32 +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 69F2D160B52 for ; Tue, 14 Feb 2017 15:36:30 +0100 (CET) Received: (qmail 51267 invoked by uid 500); 14 Feb 2017 14:36:29 -0000 Mailing-List: contact user-help@kylin.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@kylin.apache.org Delivered-To: mailing list user@kylin.apache.org Received: (qmail 51251 invoked by uid 99); 14 Feb 2017 14:36:29 -0000 Received: from mail-relay.apache.org (HELO mail-relay.apache.org) (140.211.11.15) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 14 Feb 2017 14:36:29 +0000 Received: from mail-ot0-f180.google.com (mail-ot0-f180.google.com [74.125.82.180]) by mail-relay.apache.org (ASF Mail Server at mail-relay.apache.org) with ESMTPSA id 38D8F1A00A2 for ; Tue, 14 Feb 2017 14:36:29 +0000 (UTC) Received: by mail-ot0-f180.google.com with SMTP id 65so94196893otq.2 for ; Tue, 14 Feb 2017 06:36:29 -0800 (PST) X-Gm-Message-State: AMke39nLG2f1MGu6UBg/v3mQbz/z4CNMUfH+WUq8P6MPJITwmeHXxeYhAUNz/RqRRXCM/UFpAbxjMOQJMVAZUQ== X-Received: by 10.157.15.103 with SMTP id 94mr15921599ott.104.1487082987860; Tue, 14 Feb 2017 06:36:27 -0800 (PST) MIME-Version: 1.0 Received: by 10.74.153.125 with HTTP; Tue, 14 Feb 2017 06:35:47 -0800 (PST) In-Reply-To: <62AF2D9BCDE35E4DBC186721298D0F7B014F7E6A@MBX28.360buyAD.local> References: <62AF2D9BCDE35E4DBC186721298D0F7B014F7E6A@MBX28.360buyAD.local> From: ShaoFeng Shi Date: Tue, 14 Feb 2017 22:35:47 +0800 X-Gmail-Original-Message-ID: Message-ID: Subject: =?UTF-8?B?UmU6IOWFs+S6jmt5bGlu5p+l6K+i6Zeu6aKY5ZKo6K+i?= To: user Content-Type: multipart/alternative; boundary=94eb2c0368523e408105487e7de6 archived-at: Tue, 14 Feb 2017 14:36:32 -0000 --94eb2c0368523e408105487e7de6 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Kaisen made several performance improvement on the bitmap measure; You can check http://mt.sohu.com/20170113/n478613681.shtml if haven't. BTW, these improvements will be included in the 2.0 release; 2017-02-14 11:05 GMT+08:00 =E4=BB=87=E5=90=8C=E5=BF=83 : > =E5=A4=A7=E5=AE=B6=E5=A5=BD=EF=BC=9A > > =E7=9B=AE=E5=89=8D=E5=9C=A8=E4=BD=BF=E7=94=A8=E4=B8=AD=E9=81=87=E5=88=B0= =E4=B8=80=E4=B8=AAkylin=E6=9F=A5=E8=AF=A2=E6=85=A2=E7=9A=84=E5=9C=BA=E6=99= =AF: > > Cube =E8=AE=BE=E8=AE=A1=E5=A6=82=E4=B8=8B=EF=BC=9A > > { > > "uuid": "dfb77a08-f51d-4088-b559-1da67c28a068", > > "last_modified": 1486997875953, > > "version": "1.6.0", > > "name": "insu_t", > > "model_name": "insu_jdmall_model_test", > > "description": "", > > "null_string": null, > > "dimensions": [ > > { > > "name": "BRAND", > > "table": "DMT.DMT_KYLIN_JDMALL_ORDR_DTL_I_D", > > "column": "BRAND_CD", > > "derived": null > > }, > > { > > "name": "DT", > > "table": "DMT.DMT_KYLIN_JDMALL_ORDR_DTL_I_D", > > "column": "DT", > > "derived": null > > }, > > { > > "name": "DIM.DIM_DAY_DERIVED", > > "table": "DIM.DIM_DAY", > > "column": null, > > "derived": [ > > "DIM_DAY_NAME", > > "DIM_WEEK_NAME", > > "DIM_MONTH_NAME" > > ] > > }, > > { > > "name": "FIRST", > > "table": "DIM.DIM_ITEM_GEN_THIRD_CATE_D", > > "column": "ITEM_FIRST_CATE_NAME", > > "derived": null > > }, > > { > > "name": "SECOND", > > "table": "DIM.DIM_ITEM_GEN_THIRD_CATE_D", > > "column": "ITEM_SECOND_CATE_NAME", > > "derived": null > > }, > > { > > "name": "THIRD", > > "table": "DIM.DIM_ITEM_GEN_THIRD_CATE_D", > > "column": "ITEM_THIRD_CATE_NAME", > > "derived": null > > } > > ], > > "measures": [ > > { > > "name": "_COUNT_", > > "function": { > > "expression": "COUNT", > > "parameter": { > > "type": "constant", > > "value": "1", > > "next_parameter": null > > }, > > "returntype": "bigint" > > }, > > "dependent_measure_ref": null > > }, > > { > > "name": "QTTY", > > "function": { > > "expression": "SUM", > > "parameter": { > > "type": "column", > > "value": "SALE_QTTY", > > "next_parameter": null > > }, > > "returntype": "bigint" > > }, > > "dependent_measure_ref": null > > }, > > { > > "name": "BEFORE", > > "function": { > > "expression": "SUM", > > "parameter": { > > "type": "column", > > "value": "BEFORE_PREFR_AMOUNT", > > "next_parameter": null > > }, > > "returntype": "decimal(25,4)" > > }, > > "dependent_measure_ref": null > > }, > > { > > "name": "USER", > > "function": { > > "expression": "SUM", > > "parameter": { > > "type": "column", > > "value": "USER_ACTUAL_PAY_AMOUNT", > > "next_parameter": null > > }, > > "returntype": "decimal(25,4)" > > }, > > "dependent_measure_ref": null > > }, > > { > > "name": "SALE", > > "function": { > > "expression": "COUNT_DISTINCT", > > "parameter": { > > "type": "column", > > "value": "SALE_ORD_ID", > > "next_parameter": null > > }, > > "returntype": "bitmap" > > }, > > "dependent_measure_ref": null > > } > > ], > > "dictionaries": [], > > "rowkey": { > > "rowkey_columns": [ > > { > > "column": "BRAND_CD", > > "encoding": "dict", > > "isShardBy": false > > }, > > { > > "column": "DT", > > "encoding": "dict", > > "isShardBy": false > > }, > > { > > "column": "ITEM_FIRST_CATE_NAME", > > "encoding": "dict", > > "isShardBy": false > > }, > > { > > "column": "ITEM_SECOND_CATE_NAME", > > "encoding": "dict", > > "isShardBy": false > > }, > > { > > "column": "ITEM_THIRD_CATE_NAME", > > "encoding": "dict", > > "isShardBy": false > > } > > ] > > }, > > "hbase_mapping": { > > "column_family": [ > > { > > "name": "F1", > > "columns": [ > > { > > "qualifier": "M", > > "measure_refs": [ > > "_COUNT_", > > "QTTY", > > "BEFORE", > > "USER" > > ] > > } > > ] > > }, > > { > > "name": "F2", > > "columns": [ > > { > > "qualifier": "M", > > "measure_refs": [ > > "SALE" > > ] > > } > > ] > > } > > ] > > }, > > "aggregation_groups": [ > > { > > "includes": [ > > "BRAND_CD", > > "DT", > > "ITEM_FIRST_CATE_NAME", > > "ITEM_SECOND_CATE_NAME", > > "ITEM_THIRD_CATE_NAME" > > ], > > "select_rule": { > > "hierarchy_dims": [], > > "mandatory_dims": [], > > "joint_dims": [] > > } > > } > > ], > > "signature": "Kl5sPTVN78bEYTGKoUOsWg=3D=3D", > > "notify_list": [], > > "status_need_notify": [ > > "ERROR", > > "DISCARDED", > > "SUCCEED" > > ], > > "partition_date_start": 1483747200000, > > "partition_date_end": 3153600000000, > > "auto_merge_time_ranges": [ > > 604800000, > > 2419200000 > > ], > > "retention_range": 0, > > "engine_type": 2, > > "storage_type": 2, > > "override_kylin_properties": { > > "kylin.hbase.region.cut": "1" > > } > > } > > > > =E6=95=B0=E6=8D=AE=E9=87=8F=E6=98=AF14=E5=A4=A9=E7=9A=84=E6=95=B0=E6=8D= =AE=EF=BC=8Csale_ord_id=E7=9A=84=E5=9F=BA=E6=95=B0=E6=98=AF1.5=E4=BA=BF > > Select dt,item_second_cate_name,count(distinct sale_ord_id),sum(sale_qtty= ) > > from DMT.DMT_KYLIN_JDMALL_ORDR_DTL_I_D a > > left join dim.dim_day b on a.dt =3D b.dim_day_txdate > > left join DIM.DIM_ITEM_GEN_THIRD_CATE_D c on a.item_third_cate_cd =3D > c.item_third_cate_id > > group by dt,item_second_cate_name; > > > > =E8=BF=99=E6=9D=A1=E8=AF=AD=E5=8F=A5=E6=89=A7=E8=A1=8C=E6=97=B6=E9=97=B4= =E6=98=AF37=E7=A7=92,=E5=8E=BB=E6=8E=89count(distinct sale_ord_id)=E5=90=8E= =E6=9F=A5=E8=AF=A2=E6=97=B60.07=E7=A7=92 > > dt,item_second_cate_name =E9=83=BD=E6=98=AFnormal=E7=BB=B4=E5=BA=A6=EF=BC= =8C=E4=BB=8E=E7=BB=93=E6=9E=9C=E7=9C=8B=E6=98=AFcount_distinct > =E5=BA=A6=E9=87=8F=E5=AF=BC=E8=87=B4=E7=9A=84=E6=85=A2=E6=9F=A5=E8=AF=A2= =EF=BC=8C=E8=AF=B7=E9=97=AE=E8=BF=99=E4=B8=AA=E6=9C=89=E4=BB=80=E4=B9=88=E4= =BC=98=E5=8C=96=E7=9A=84=E5=BB=BA=E8=AE=AE=E5=90=97=EF=BC=9F > > > > =E8=B0=A2=E8=B0=A2=EF=BC=81 > > > > > > > --=20 Best regards, Shaofeng Shi =E5=8F=B2=E5=B0=91=E9=94=8B --94eb2c0368523e408105487e7de6 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Kaisen made several performance improvement on the bitmap = measure; You can check=C2=A0http://mt.sohu.com/20170113/n478613681.shtml if haven't.<= div>
BTW, these improvements will be included in the 2.0 rele= ase;

2= 017-02-14 11:05 GMT+08:00 =E4=BB=87=E5=90=8C=E5=BF=83 <= ;qiutongxin@jd.com>:

=E5= =A4=A7=E5=AE=B6=E5=A5=BD=EF=BC=9A=

=E7=9B=AE=E5=89=8D=E5=9C=A8=E4=BD=BF=E7=94=A8=E4=B8= =AD=E9=81=87=E5=88=B0=E4=B8=80=E4=B8=AAkylin=E6=9F=A5=E8=AF=A2=E6=85= =A2=E7=9A=84=E5=9C=BA=E6=99=AF:

Cu= be =C2=A0=E8=AE=BE=E8= =AE=A1=E5=A6=82=E4=B8=8B=EF=BC=9A=

{

=C2=A0 "uuid": "dfb77a08-f51d-4088-b559-1da67c2= 8a068",

=C2=A0 "last_modified": 1486997875953,

=C2=A0 "version": "1.6.0",=

=C2=A0 "name": "insu_t",

=C2=A0 "model_name": "insu_jdmall_model_test",<= u>

=C2=A0 "description": "",<= /p>

=C2=A0 "null_string": null,

=C2=A0 "dimensions": [

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "BRAND",=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "table": "DMT.DMT_KYL= IN_JDMALL_ORDR_DTL_I_D",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": "BRAND_CD&q= uot;,

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "derived": null<= /u>

=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "DT",=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "table": "DMT.DMT_KYL= IN_JDMALL_ORDR_DTL_I_D",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": "DT",<= u>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "derived": null<= /u>

=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "DIM.DIM_DAY_= DERIVED",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "table": "DIM.DIM_DAY= ",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": null,<= /u>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "derived": [=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "DIM_DAY_NAME"= ,

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "DIM_WEEK_NAME"= ;,

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "DIM_MONTH_NAME&quo= t;

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ]

=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "FIRST",=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0"table": "DIM.DIM_ITEM= _GEN_THIRD_CATE_D",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": "ITEM_FIRST= _CATE_NAME",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "derived": null<= /u>

=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "SECOND"= ,

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "table": "DIM.DIM_ITE= M_GEN_THIRD_CATE_D",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": "ITEM_SECON= D_CATE_NAME",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "derived": null<= /u>

=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "THIRD",=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "table": "DIM.DIM_ITE= M_GEN_THIRD_CATE_D",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": "ITEM_THIRD= _CATE_NAME",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "derived": null<= /u>

=C2=A0=C2=A0=C2=A0 }

=C2=A0 ],

=C2=A0 "measures": [

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "_COUNT_"= ;,

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "function": {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "expression": = "COUNT",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "parameter": {=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "type&q= uot;: "constant",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "value&= quot;: "1",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "next_p= arameter": null

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },<= /p>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "returntype": = "bigint"

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "dependent_measure_ref": n= ull

=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "QTTY",<= u>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "function": {

=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0=C2=A0"expression": = "SUM",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "parameter": {=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "type&q= uot;: "column",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "value&= quot;: "SALE_QTTY",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "next_p= arameter": null

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },<= /p>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "returntype": = "bigint"

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "dependent_measure_ref": n= ull

=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "BEFORE"= ,

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "function": {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "expression": = "SUM",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "parameter": {=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "type&q= uot;: "column",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "value&= quot;: "BEFORE_PREFR_AMOUNT",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "next_p= arameter": null

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },<= /p>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "returntype": = "decimal(25,4)"

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0 =C2=A0"dependent_measure_ref": n= ull

=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "USER",<= u>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "function": {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "expression": = "SUM",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "parameter": {=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "type&q= uot;: "column",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "value&= quot;: "USER_ACTUAL_PAY_AMOUNT",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "next_p= arameter": null

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },<= /p>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0"returntype": &= quot;decimal(25,4)"

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "dependent_measure_ref": n= ull

=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "SALE",<= u>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "function": {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "expression": = "COUNT_DISTINCT",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "parameter": {=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "type&q= uot;: "column",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "value&= quot;: "SALE_ORD_ID",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "next_p= arameter": null

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },<= /p>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "returntype": = "bitmap"

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "dependent_measure_ref": n= ull

=C2=A0=C2=A0=C2=A0 }

=C2=A0 ],

=C2=A0 "dictionaries": [],

=C2=A0 "rowkey": {

=C2=A0=C2=A0=C2=A0 "rowkey_columns": [

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": &quo= t;BRAND_CD",

=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0"encoding": &q= uot;dict",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "isShardBy": f= alse

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": &quo= t;DT",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "encoding": &q= uot;dict",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "isShardBy": f= alse

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": &quo= t;ITEM_FIRST_CATE_NAME",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "encoding": &q= uot;dict",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "isShardBy": f= alse

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": &quo= t;ITEM_SECOND_CATE_NAME",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "encoding": &q= uot;dict",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "isShardBy": f= alse

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "column": &quo= t;ITEM_THIRD_CATE_NAME",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "encoding": &q= uot;dict",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "isShardBy": f= alse

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 }

=C2=A0=C2=A0=C2=A0 ]

=C2=A0 },

=C2=A0 "hbase_mapping": {

=C2=A0=C2=A0=C2=A0 "column_family": [

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "= F1",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "columns": [

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 {<= /u>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 = "qualifier": "M",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 = "measure_refs": [

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 "_COUNT_",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 "QTTY",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 "BEFORE",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0"USER"

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 = ]

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 }<= /u>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ]

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 },

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "name": "= F2",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "columns": [

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 {<= /u>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 = "qualifier": "M",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 = "measure_refs": [

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 "SALE"

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 = ]

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 }<= /u>

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ]

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 }

=C2=A0=C2=A0=C2=A0 ]

=C2=A0 },

=C2=A0 "aggregation_groups": [

=C2=A0=C2=A0=C2=A0 {

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "includes": [

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "BRAND_CD",=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "DT",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "ITEM_FIRST_CATE_NA= ME",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "ITEM_SECOND_CATE_N= AME",

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "ITEM_THIRD_CATE_NA= ME"

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ],

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "select_rule": {=

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "hierarchy_dims&quo= t;: [],

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "mandatory_dims&quo= t;: [],

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "joint_dims": = []

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 }

=C2=A0=C2=A0=C2=A0 }

=C2=A0 ],

=C2=A0 "signature": "Kl5sPTVN78bEYTGKoUOsWg=3D=3D&qu= ot;,

=C2=A0 "notify_list": [],

=C2=A0 "status_need_notify": [

=C2=A0=C2=A0=C2=A0 "ERROR",

=C2=A0=C2=A0=C2=A0 "DISCARDED",

=C2=A0=C2=A0=C2=A0 "SUCCEED"

=C2=A0 ],

=C2=A0 "partition_date_start": 1483747200000,

=C2=A0 "partition_date_end": 3153600000000,=

=C2=A0 "auto_merge_time_ranges": [

=C2=A0=C2=A0=C2=A0 604800000,

=C2=A0=C2=A0=C2=A0 2419200000

=C2=A0 ],

=C2=A0 "retention_range": 0,

=C2=A0 "engine_type": 2,

=C2=A0 "storage_type": 2,

=C2=A0 "override_kylin_properties": {

=C2=A0=C2=A0=C2=A0 "kylin.hbase.region.cut": "1"= ;

=C2=A0 }

}

=C2=A0

=E6=95=B0=E6=8D=AE=E9=87=8F=E6=98=AF14=E5=A4= =A9=E7=9A=84=E6=95=B0=E6=8D=AE=EF=BC=8Csale_ord_id= =E7=9A=84=E5=9F=BA=E6=95=B0=E6=98=AF1.5=E4=BA=BF

Select dt,item_second_cate_name,count(distinct sale_ord_id),su= m(sale_qtty)

from DMT.DMT_KYLIN_JDMALL_ORDR_DTL_I_D a

left join dim.dim_day b on a.dt =3D b.dim_day_txdate

left join DIM.DIM_ITEM_GEN_THIRD_CATE_D c on a.item_third_cate_cd = =3D c.item_third_cate_id

group by dt,item_second_cate_name;

=C2=A0

=E8=BF=99=E6=9D=A1=E8=AF=AD=E5=8F=A5=E6=89=A7=E8=A1=8C=E6=97=B6=E9=97=B4= =E6=98=AF37=E7=A7=92,=E5= =8E=BB=E6=8E=89count(distinct sale_ord_id)=E5=90=8E=E6=9F=A5=E8=AF=A2=E6=97=B60.07=E7=A7=92

dt,item_second_cate_name =E9=83=BD=E6=98=AFnormal=E7=BB=B4=E5=BA= =A6=EF=BC=8C=E4=BB=8E=E7=BB=93=E6=9E=9C=E7=9C=8B=E6=98=AFco= unt_distinct=E5=BA=A6=E9=87=8F=E5=AF=BC=E8=87=B4=E7=9A=84=E6= =85=A2=E6=9F=A5=E8=AF=A2=EF=BC=8C=E8=AF=B7=E9=97=AE=E8=BF=99=E4=B8=AA=E6=9C= =89=E4=BB=80=E4=B9=88=E4=BC=98=E5=8C=96=E7=9A=84=E5=BB=BA=E8=AE=AE=E5=90=97= =EF=BC=9F

=C2=A0

=E8=B0=A2=E8=B0=A2=EF=BC=81

=C2=A0

=C2=A0

=C2=A0




--
Best regards,

Shaofeng Shi =E5=8F=B2= =E5=B0=91=E9=94=8B

--94eb2c0368523e408105487e7de6--