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

Billy Liu updated KYLIN-3283:
-----------------------------
    Fix Version/s: v2.4.0

> Support values RelNode
> ----------------------
>
>                 Key: KYLIN-3283
>                 URL: https://issues.apache.org/jira/browse/KYLIN-3283
>             Project: Kylin
>          Issue Type: New Feature
>          Components: Query Engine
>    Affects Versions: v2.3.0
>            Reporter: yiming.xu
>            Assignee: yiming.xu
>            Priority: Major
>             Fix For: v2.4.0
>
>
> for queries like:
> select leaf_categ_id, sum(price) as sum_price from test_kylin_fact  group by 
> leaf_categ_id
> union all
> select 1 as leaf_categ_id2, 2 as sum_price2 
> the expected logical plan after volcano is:
> {code:java}
> OLAPToEnumerableConverter
>   OLAPLimitRel(ctx=[], fetch=[50000])
>     OLAPUnionRel(all=[true], ctx=[], all=[true])
>       OLAPAggregateRel(group=[{0}], SUM_PRICE=[SUM($1)], ctx=[])
>         OLAPProjectRel(LEAF_CATEG_ID=[$4], PRICE=[$8], ctx=[])
>           OLAPTableScan(table=[[DEFAULT, TEST_KYLIN_FACT]], ctx=[], 
> fields=[[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 
> 19, 20, 21, 22, 23, 24, 25, 26]])
>       OLAPProjectRel(LEAF_CATEG_ID2=[1], SUM_PRICE2=[2], ctx=[])
>         OLAPValuesRel(type=[RecordType(INTEGER ZERO)], tuples=[[{ 0 }]])
> {code}
> however the actual is:
> {code:java}
> EnumerableLimit(fetch=[50000])
>   EnumerableUnion(all=[true])
>     OLAPToEnumerableConverter
>       OLAPAggregateRel(group=[{0}], SUM_PRICE=[SUM($1)], ctx=[])
>         OLAPProjectRel(LEAF_CATEG_ID=[$4], PRICE=[$8], ctx=[])
>           OLAPTableScan(table=[[DEFAULT, TEST_KYLIN_FACT]], ctx=[], 
> fields=[[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 
> 19, 20, 21, 22, 23, 24, 25, 26]])
>     EnumerableCalc(expr#0=[{inputs}], expr#1=[1], expr#2=[2], 
> LEAF_CATEG_ID2=[$t1], SUM_PRICE2=[$t2])
>       EnumerableValues(type=[RecordType(INTEGER ZERO)], tuples=[[{ 0 }]])
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to