You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@kylin.apache.org by "yangzhang (Jira)" <ji...@apache.org> on 2019/12/10 09:18:00 UTC

[jira] [Updated] (KYLIN-4287) SegmentPruner cannot prune segment with "IN" or "OR" CompareTupleFilter

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

yangzhang updated KYLIN-4287:
-----------------------------
    Description: 
repro steps:

build 2 segs in a cube, [2012-01-01 - 2012-01-03]  And [2012-01-03 - 2012-01-05]

query: select sum(PRICE) from KYLIN_SALES
 where "KYLIN_SALES"."PART_DT" = DATE '2012-01-01'
 OR "KYLIN_SALES"."PART_DT" = DATE '2020-07-02'

Expected results:segment[2012-01-03 - 2012-01-05] should not be scaned, should be pruned by SegmentPruner

 

but i found in method 'org.apache.kylin.cube.common.SegmentPruner#satisfy'

when filter's operator is "In", when satisfy segment[2012-01-03 - 2012-01-05] ,the function return true

to fix this bug, [https://github.com/apache/kylin/pull/984/files]

  was:
repro steps:

build 2 segs in a cube, [2012-01-01 - 2012-01-03]  And [2012-01-03 - 2012-01-05]

query: select sum(PRICE) from KYLIN_SALES
where "KYLIN_SALES"."PART_DT" = DATE '2012-01-01'
 OR "KYLIN_SALES"."PART_DT" = DATE '2020-07-02'

Expected results:segment[2012-01-03 - 2012-01-05] should not be scaned, should be pruned by SegmentPruner

 

but i found in method 'org.apache.kylin.cube.common.SegmentPruner#satisfy'

when filter's operator is "In", when satisfy segment[2012-01-03 - 2012-01-05] ,the function return true


> SegmentPruner cannot prune segment with "IN" or "OR" CompareTupleFilter
> -----------------------------------------------------------------------
>
>                 Key: KYLIN-4287
>                 URL: https://issues.apache.org/jira/browse/KYLIN-4287
>             Project: Kylin
>          Issue Type: Improvement
>          Components: Query Engine
>            Reporter: yangzhang
>            Assignee: yangzhang
>            Priority: Major
>
> repro steps:
> build 2 segs in a cube, [2012-01-01 - 2012-01-03]  And [2012-01-03 - 2012-01-05]
> query: select sum(PRICE) from KYLIN_SALES
>  where "KYLIN_SALES"."PART_DT" = DATE '2012-01-01'
>  OR "KYLIN_SALES"."PART_DT" = DATE '2020-07-02'
> Expected results:segment[2012-01-03 - 2012-01-05] should not be scaned, should be pruned by SegmentPruner
>  
> but i found in method 'org.apache.kylin.cube.common.SegmentPruner#satisfy'
> when filter's operator is "In", when satisfy segment[2012-01-03 - 2012-01-05] ,the function return true
> to fix this bug, [https://github.com/apache/kylin/pull/984/files]



--
This message was sent by Atlassian Jira
(v8.3.4#803005)