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

pengfei.zhan resolved KYLIN-5740.
---------------------------------
    Fix Version/s: 5.0-beta
                       (was: 5.0.0)
       Resolution: Fixed

> Equivalent aggregations matches index failed when using the strategy of 
> dimension as measure.
> ---------------------------------------------------------------------------------------------
>
>                 Key: KYLIN-5740
>                 URL: https://issues.apache.org/jira/browse/KYLIN-5740
>             Project: Kylin
>          Issue Type: Bug
>    Affects Versions: 5.0-beta
>            Reporter: zhong.zhu
>            Assignee: zhong.zhu
>            Priority: Critical
>             Fix For: 5.0-beta
>
>         Attachments: image-2023-12-11-14-25-14-409.png, 
> image-2023-12-11-14-32-11-954.png, image-2023-12-11-14-36-45-263.png, 
> image-2023-12-11-14-37-08-556.png
>
>
> Reproduction method:
> Table Building Statements
> {code:sql}
> CREATE EXTERNAL TABLE LT859 (
>     `PRO_MT_SEASON` varchar(4096),
>     `ARRIVAL_TRANSIT_IN_PRM_AMT` decimal(18,4),
>     `BIG_REGION_NAME` varchar(4096),
>     `REGION_NAME` varchar(4096)
> ) ROW FORMAT DELIMITED FIELDS TERMINATED BY ','
> STORED AS TEXTFILE;LOAD DATA INPATH '/path/to/data/LT859.csv' OVERWRITE INTO 
> TABLE LT859;
> {code}
> Data(LT859.csv)
> {code:bash}
> 22Q1,150.12,东区,华东区
> 22Q2,200.59,中区,华中区
> 22Q3,301.55,上海区,华东区
> {code}
> Select SQL:
> {code:sql}
> select
>   max(BIG_REGION_NAME) "max1",
>   max(
>     case when 1=1 then "BIG_REGION_NAME"
>     end
>   ) "max2"
> from XXX.LT859
> {code}
> Create model, dimension 4 columns selected, add metrics MAX(BIG_REGION_NAME)
> Save the model and delete the base aggregation index, manually add an 
> aggregation group as a replacement for the base aggregation, but it can't 
> have the MAX(BIG_REGION_NAME) metric in it to mimic the dim as measure 
> scenario, and build the full amount.
> Using the above select sql query, you can see that NPE is reported in the 
> background:
> !image-2023-12-11-14-25-14-409.png!



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to