> Query having Subquery alias used in query projection doesnot hit mv after creation
> ----------------------------------------------------------------------------------
>
> Key: CARBONDATA-4076
> URL:
https://issues.apache.org/jira/browse/CARBONDATA-4076> Project: CarbonData
> Issue Type: Bug
> Reporter: Indhumathi Muthu Murugesh
> Priority: Minor
> Fix For: 2.2.0
>
> Time Spent: 5h 20m
> Remaining Estimate: 0h
>
> {color:#067d17}CREATE TABLE fact_table1 (empname String, designation String, doj Timestamp,
> {color}{color:#067d17}workgroupcategory int, workgroupcategoryname String, deptno int, deptname String,
> {color}{color:#067d17}projectcode int, projectjoindate Timestamp, projectenddate Timestamp,attendance int,
> {color}{color:#067d17}utilization int,salary int)
> {color}{color:#067d17}STORED AS carbondata;{color}
> {color:#067d17}create materialized view mv_sub as select empname, sum(result) sum_ut from (select empname, utilization result from fact_table1) fact_table1 group by empname;
> {color}
>
> {color:#067d17}select empname, sum(result) sum_ut from (select empname, utilization result from fact_table1) fact_table1 group by empname;{color}
>
> {color:#067d17}explain select empname, sum(result) sum_ut from (select empname, utilization result from fact_table1) fact_table1 group by empname;{color}
>
> {color:#067d17}Expected: Query should hit MV{color}
> {color:#067d17}Actual: Query is not hitting MV{color}
>
>