[ 
https://issues.apache.org/jira/browse/KYLIN-1693?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Shaofeng SHI updated KYLIN-1693:
--------------------------------
    Fix Version/s: v1.5.3
       Issue Type: New Feature  (was: Wish)

I'm working on this; will be able to specify multiple group by columns in one 
TopN measure, like this:

{code}
 {
      "name": "TOP",
      "function": {
        "expression": "TOP_N",
        "parameter": {
          "type": "column",
          "value": "PRICE",
          "next_parameter": {
            "type": "column",
            "value": "SELLER_ID",
            "next_parameter": {
              "type": "column",
              "value": "LEAF_CATEG_ID",
              "next_parameter": null
            }
          }
        },
        "configuration": {},
        "returntype": "topn(100)"
      }
    }

{code}

The query would be :

{code}
select LEAF_CATEG_ID, seller_id, sum(price) total_price from test_kylin_fact 
group by LEAF_CATEG_ID, seller_id order by total_price desc limit 200;
{code}

> Support multiple group-by columns for TOP_N meausre
> ---------------------------------------------------
>
>                 Key: KYLIN-1693
>                 URL: https://issues.apache.org/jira/browse/KYLIN-1693
>             Project: Kylin
>          Issue Type: New Feature
>          Components: Query Engine
>    Affects Versions: v1.5.1
>            Reporter: JunAn Chen
>            Assignee: Shaofeng SHI
>            Priority: Minor
>             Fix For: v1.5.3
>
>
> For this case:
> table name : "tbl"
> columns:  (dim_city, dim_industry, keyword, pv)
> the "keyword" column has a large cardinality, for about ten million.
> currently I can build "top100 pv" in (dim_city), (dim_industry). 
> But I also want to build "top100 pv" in (dim_city, dim_industry) and "top100 
> pv of keyword" in (dim_city), (dim_industry) and (dim_city, dim_industrt).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to