You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kylin.apache.org by xx...@apache.org on 2020/10/10 09:34:44 UTC

[kylin] branch kylin-on-parquet-v2 updated: KYLIN-4782 Verify if the query hit the true cuboid in IT

This is an automated email from the ASF dual-hosted git repository.

xxyu pushed a commit to branch kylin-on-parquet-v2
in repository https://gitbox.apache.org/repos/asf/kylin.git


The following commit(s) were added to refs/heads/kylin-on-parquet-v2 by this push:
     new 9b2a12b  KYLIN-4782 Verify if the query hit the true cuboid in IT
9b2a12b is described below

commit 9b2a12bc334edf4f8756a1a758c941a4571efa78
Author: rupengwang <wa...@live.cn>
AuthorDate: Sat Oct 10 16:02:02 2020 +0800

    KYLIN-4782 Verify if the query hit the true cuboid in IT
---
 .../org/apache/kylin/common/KylinConfigBase.java   |   2 +-
 .../java/org/apache/kylin/common/util/Triple.java  |  95 ++++++
 kylin-it/src/test/resources/query/sql/query00.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query01.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query02.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query03.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query04.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query05.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query06.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query07.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query08.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query09.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query10.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query100.sql |   2 +-
 kylin-it/src/test/resources/query/sql/query101.sql |   2 +-
 kylin-it/src/test/resources/query/sql/query102.sql |   2 +-
 kylin-it/src/test/resources/query/sql/query103.sql |   2 +-
 kylin-it/src/test/resources/query/sql/query104.sql |   2 +-
 kylin-it/src/test/resources/query/sql/query105.sql |   1 +
 kylin-it/src/test/resources/query/sql/query106.sql |   1 +
 kylin-it/src/test/resources/query/sql/query107.sql |   1 +
 kylin-it/src/test/resources/query/sql/query108.sql |   1 +
 kylin-it/src/test/resources/query/sql/query109.sql |   1 +
 kylin-it/src/test/resources/query/sql/query11.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query110.sql |   2 +-
 kylin-it/src/test/resources/query/sql/query112.sql |   2 +-
 kylin-it/src/test/resources/query/sql/query113.sql |   2 +-
 kylin-it/src/test/resources/query/sql/query114.sql |   2 +-
 kylin-it/src/test/resources/query/sql/query12.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query13.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query14.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query15.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query16.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query17.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query18.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query19.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query20.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query21.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query22.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query23.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query24.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query25.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query26.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query27.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query28.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query29.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query30.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query31.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query32.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query33.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query34.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query35.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query36.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query37.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query38.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query39.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query40.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query41.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query42.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query43.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query44.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query49.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query50.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query51.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query52.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query53.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query54.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query55.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query56.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query57.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query58.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query59.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query60.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query61.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query62.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query63.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query64.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query65.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query66.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query67.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query68.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query69.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query70.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query71.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query72.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query73.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query74.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query75.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query76.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query77.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query78.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query79.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query80.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query83.sql  |   2 +-
 kylin-it/src/test/resources/query/sql/query84.sql  |   2 +-
 kylin-it/src/test/resources/query/sql/query85.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query86.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query87.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query88.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query89.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query90.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query91.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query92.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query93.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query94.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query95.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query96.sql  |   2 +-
 kylin-it/src/test/resources/query/sql/query97.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query98.sql  |   1 +
 kylin-it/src/test/resources/query/sql/query99.sql  |   1 +
 .../src/test/resources/query/sql_cache/query01.sql |   1 +
 .../src/test/resources/query/sql_cache/query02.sql |   1 +
 .../src/test/resources/query/sql_cache/query03.sql |   1 +
 .../src/test/resources/query/sql_cache/query04.sql |   1 +
 .../src/test/resources/query/sql_cache/query05.sql |   1 +
 .../src/test/resources/query/sql_cache/query06.sql |   1 +
 .../src/test/resources/query/sql_cache/query07.sql |   1 +
 .../src/test/resources/query/sql_cache/query08.sql |   1 +
 .../src/test/resources/query/sql_cache/query09.sql |   1 +
 .../test/resources/query/sql_casewhen/query00.sql  |   1 +
 .../test/resources/query/sql_casewhen/query01.sql  |   1 +
 .../test/resources/query/sql_casewhen/query02.sql  |   1 +
 .../test/resources/query/sql_casewhen/query03.sql  |   1 +
 .../test/resources/query/sql_casewhen/query04.sql  |   1 +
 .../test/resources/query/sql_casewhen/query55.sql  |   1 +
 .../test/resources/query/sql_casewhen/query56.sql  |   1 +
 .../test/resources/query/sql_casewhen/query57.sql  |   2 +-
 .../test/resources/query/sql_datetime/query00.sql  |   2 +-
 .../test/resources/query/sql_derived/query01.sql   |   1 +
 .../test/resources/query/sql_derived/query02.sql   |   1 +
 .../test/resources/query/sql_derived/query03.sql   |   1 +
 .../test/resources/query/sql_derived/query04.sql   |   1 +
 .../test/resources/query/sql_derived/query05.sql   |   1 +
 .../test/resources/query/sql_derived/query06.sql   |   1 +
 .../test/resources/query/sql_derived/query07.sql   |   1 +
 .../test/resources/query/sql_derived/query09.sql   |   1 +
 .../test/resources/query/sql_derived/query10.sql   |   1 +
 .../test/resources/query/sql_derived/query11.sql   |   1 +
 .../test/resources/query/sql_derived/query12.sql   |   2 +-
 .../test/resources/query/sql_derived/query13.sql   |   2 +-
 .../test/resources/query/sql_distinct/query00.sql  |   1 +
 .../test/resources/query/sql_distinct/query01.sql  |   1 +
 .../test/resources/query/sql_distinct/query02.sql  |   1 +
 .../test/resources/query/sql_distinct/query03.sql  |   1 +
 .../test/resources/query/sql_distinct/query04.sql  |   1 +
 .../test/resources/query/sql_distinct/query05.sql  |   1 +
 .../test/resources/query/sql_distinct/query06.sql  |   1 +
 .../test/resources/query/sql_distinct/query07.sql  |   1 +
 .../resources/query/sql_distinct_dim/query100.sql  |   2 +-
 .../resources/query/sql_distinct_dim/query101.sql  |   2 +-
 .../query/sql_distinct_precisely/query00.sql       |   1 +
 .../query/sql_distinct_precisely/query01.sql       |   1 +
 .../query/sql_distinct_precisely/query02.sql       |   1 +
 .../query/sql_distinct_precisely/query03.sql       |   1 +
 .../query/sql_distinct_precisely/query04.sql       |   1 +
 .../test/resources/query/sql_grouping/query00.sql  |   2 +-
 .../test/resources/query/sql_grouping/query01.sql  |   2 +-
 .../test/resources/query/sql_grouping/query02.sql  |   1 +
 .../resources/query/sql_h2_uncapable/query03.sql   |   2 +-
 .../resources/query/sql_h2_uncapable/query04.sql   |   2 +-
 .../resources/query/sql_h2_uncapable/query05.sql   |   1 +
 .../src/test/resources/query/sql_join/query_00.sql |   2 +-
 .../src/test/resources/query/sql_like/query01.sql  |   1 +
 .../src/test/resources/query/sql_like/query02.sql  |   2 +-
 .../src/test/resources/query/sql_like/query03.sql  |   2 +-
 .../src/test/resources/query/sql_like/query04.sql  |   2 +-
 .../src/test/resources/query/sql_like/query05.sql  |   1 +
 .../src/test/resources/query/sql_like/query06.sql  |   1 +
 .../src/test/resources/query/sql_like/query10.sql  |   1 +
 .../src/test/resources/query/sql_like/query15.sql  |   1 +
 .../src/test/resources/query/sql_like/query16.sql  |   1 +
 .../src/test/resources/query/sql_like/query17.sql  |   1 +
 .../src/test/resources/query/sql_like/query18.sql  |   1 +
 .../src/test/resources/query/sql_like/query20.sql  |   2 +-
 .../src/test/resources/query/sql_like/query21.sql  |   2 +-
 .../src/test/resources/query/sql_like/query22.sql  |   1 +
 .../src/test/resources/query/sql_like/query23.sql  |   1 +
 .../test/resources/query/sql_lookup/query01.sql    |   1 +
 .../test/resources/query/sql_lookup/query02.sql    |   1 +
 .../test/resources/query/sql_lookup/query03.sql    |   1 +
 .../test/resources/query/sql_lookup/query04.sql    |   1 +
 .../test/resources/query/sql_lookup/query05.sql    |   1 +
 .../test/resources/query/sql_lookup/query06.sql    |   2 +-
 .../test/resources/query/sql_lookup/query07.sql    |   1 +
 .../test/resources/query/sql_lookup/query45.sql    |   1 +
 .../test/resources/query/sql_lookup/query46.sql    |   1 +
 .../test/resources/query/sql_lookup/query47.sql    |   1 +
 .../test/resources/query/sql_lookup/query48.sql    |   1 +
 .../test/resources/query/sql_lookup/query55.sql    |   1 +
 .../test/resources/query/sql_orderby/query01.sql   |   1 +
 .../test/resources/query/sql_orderby/query02.sql   |   1 +
 .../test/resources/query/sql_orderby/query03.sql   |   1 +
 .../resources/query/sql_percentile/query01.sql     |   2 +-
 .../resources/query/sql_percentile/query02.sql     |   2 +-
 .../test/resources/query/sql_subquery/query00.sql  |   1 +
 .../test/resources/query/sql_subquery/query01.sql  |   1 +
 .../test/resources/query/sql_subquery/query02.sql  |   1 +
 .../test/resources/query/sql_subquery/query03.sql  |   1 +
 .../test/resources/query/sql_subquery/query04.sql  |   1 +
 .../test/resources/query/sql_subquery/query05.sql  |   1 +
 .../test/resources/query/sql_subquery/query06.sql  |   1 +
 .../test/resources/query/sql_subquery/query07.sql  |   1 +
 .../test/resources/query/sql_subquery/query08.sql  |   2 +-
 .../test/resources/query/sql_subquery/query09.sql  |   2 +-
 .../test/resources/query/sql_subquery/query10.sql  |   1 +
 .../test/resources/query/sql_subquery/query11.sql  |   1 +
 .../test/resources/query/sql_subquery/query12.sql  |   1 +
 .../test/resources/query/sql_subquery/query13.sql  |   1 +
 .../test/resources/query/sql_subquery/query14.sql  |   2 +-
 .../test/resources/query/sql_subquery/query15.sql  |   2 +-
 .../test/resources/query/sql_subquery/query16.sql  |   2 +-
 .../test/resources/query/sql_subquery/query17.sql  |   1 +
 .../test/resources/query/sql_subquery/query18.sql  |   1 +
 .../test/resources/query/sql_subquery/query19.sql  |   1 +
 .../test/resources/query/sql_subquery/query21.sql  |   1 +
 .../test/resources/query/sql_subquery/query22.sql  |   1 +
 .../test/resources/query/sql_subquery/query23.sql  |   1 +
 .../test/resources/query/sql_subquery/query24.sql  |   1 +
 .../test/resources/query/sql_subquery/query25.sql  |   1 +
 .../test/resources/query/sql_subquery/query26.sql  |   1 +
 .../test/resources/query/sql_subquery/query27.sql  |   1 +
 .../test/resources/query/sql_subquery/query28.sql  |   1 +
 .../test/resources/query/sql_subquery/query30.sql  |   1 +
 .../test/resources/query/sql_subquery/query31.sql  |   1 +
 .../test/resources/query/sql_subquery/query34.sql  |   1 +
 .../test/resources/query/sql_subquery/query37.sql  |   1 +
 .../test/resources/query/sql_tableau/query00.sql   |   1 +
 .../test/resources/query/sql_tableau/query01.sql   |   1 +
 .../test/resources/query/sql_tableau/query02.sql   |   1 +
 .../test/resources/query/sql_tableau/query03.sql   |   1 +
 .../test/resources/query/sql_tableau/query04.sql   |   1 +
 .../test/resources/query/sql_tableau/query05.sql   |   1 +
 .../test/resources/query/sql_tableau/query06.sql   |   1 +
 .../test/resources/query/sql_tableau/query07.sql   |   1 +
 .../test/resources/query/sql_tableau/query10.sql   |   1 +
 .../test/resources/query/sql_tableau/query11.sql   |   1 +
 .../test/resources/query/sql_tableau/query12.sql   |   1 +
 .../test/resources/query/sql_tableau/query13.sql   |   1 +
 .../test/resources/query/sql_tableau/query14.sql   |   1 +
 .../test/resources/query/sql_tableau/query15.sql   |   1 +
 .../test/resources/query/sql_tableau/query16.sql   |   1 +
 .../test/resources/query/sql_tableau/query17.sql   |   1 +
 .../test/resources/query/sql_tableau/query18.sql   |   1 +
 .../test/resources/query/sql_tableau/query19.sql   |   1 +
 .../test/resources/query/sql_tableau/query20.sql   |   1 +
 .../test/resources/query/sql_tableau/query21.sql   |   1 +
 .../test/resources/query/sql_tableau/query23.sql   |   1 +
 .../test/resources/query/sql_tableau/query24.sql   |   1 +
 .../test/resources/query/sql_tableau/query25.sql   |   1 +
 .../test/resources/query/sql_tableau/query27.sql   |   1 +
 .../test/resources/query/sql_tableau/query28.sql   |   1 +
 .../test/resources/query/sql_tableau/query29.sql   |   1 +
 .../test/resources/query/sql_tableau/query67.sql   |   1 +
 .../test/resources/query/sql_timestamp/query01.sql |   1 +
 .../test/resources/query/sql_timestamp/query02.sql |   1 +
 .../test/resources/query/sql_timestamp/query03.sql |   1 +
 .../test/resources/query/sql_timestamp/query05.sql |   1 +
 .../test/resources/query/sql_timestamp/query11.sql |   1 +
 .../test/resources/query/sql_timestamp/query12.sql |   1 +
 .../test/resources/query/sql_timestamp/query13.sql |   1 +
 .../test/resources/query/sql_timestamp/query14.sql |   1 +
 .../test/resources/query/sql_timestamp/query21.sql |   1 +
 .../resources/query/sql_timestamp/query21_a.sql    |   1 +
 .../test/resources/query/sql_timestamp/query22.sql |   1 +
 .../resources/query/sql_timestamp/query22_a.sql    |   1 +
 .../resources/query/sql_timestamp/query22_b.sql    |   1 +
 .../resources/query/sql_timestamp/query22_c.sql    |   1 +
 .../resources/query/sql_timestamp/query22_d.sql    |   1 +
 .../resources/query/sql_timestamp/query22_e.sql    |   1 +
 .../test/resources/query/sql_timestamp/query23.sql |   1 +
 .../resources/query/sql_timestamp/query23_a.sql    |   1 +
 .../test/resources/query/sql_timestamp/query25.sql |   1 +
 .../resources/query/sql_timestamp/query25_a.sql    |   1 +
 .../test/resources/query/sql_timestamp/query26.sql |   1 +
 .../src/test/resources/query/sql_topn/query45.sql  |   1 +
 .../src/test/resources/query/sql_topn/query81.sql  |   2 +-
 .../src/test/resources/query/sql_topn/query82.sql  |   1 +
 .../src/test/resources/query/sql_topn/query83.sql  |   1 +
 .../src/test/resources/query/sql_union/query01.sql |   1 +
 .../src/test/resources/query/sql_union/query02.sql |   1 +
 .../src/test/resources/query/sql_union/query03.sql |   1 +
 .../test/resources/query/sql_window/query00.sql    |   1 +
 .../test/resources/query/sql_window/query01.sql    |   1 +
 .../test/resources/query/sql_window/query02.sql    |   1 +
 .../test/resources/query/sql_window/query03.sql    |   2 +-
 .../test/resources/query/sql_window/query04.sql    |   1 +
 .../test/resources/query/sql_window/query05.sql    |   1 +
 .../test/resources/query/sql_window/query06.sql    |   1 +
 .../test/resources/query/sql_window/query07.sql    |   1 +
 .../test/resources/query/sql_window/query08.sql    |   1 +
 .../test/resources/query/sql_window/query09.sql    |   1 +
 .../test/resources/query/sql_window/query11.sql    |   2 +-
 .../test/resources/query/sql_window/query12.sql    |   1 +
 .../test/resources/query/sql_window/query13.sql    |   2 +-
 .../scala/org/apache/spark/sql/KylinSession.scala  |   2 +-
 .../spark2/BuildAndQueryEmptySegmentsTest.java     |  14 +-
 .../kylin/engine/spark2/NBuildAndQueryTest.java    |  11 +-
 .../apache/kylin/engine/spark2/NExecAndComp.java   | 323 +++++++++++++++++++--
 298 files changed, 701 insertions(+), 78 deletions(-)

diff --git a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java b/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
index e0d0e63..1ffdc16 100644
--- a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
+++ b/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
@@ -2827,7 +2827,7 @@ public abstract class KylinConfigBase implements Serializable {
         return Integer.parseInt(getOptional("kylin.query.spark-engine.spark-sql-shuffle-partitions", "-1"));
     }
 
-    public Map<String, String> getSparkConf() {
+    public Map<String, String> getQuerySparkConf() {
         return getPropertiesByPrefix("kylin.query.spark-conf.");
     }
 
diff --git a/core-common/src/main/java/org/apache/kylin/common/util/Triple.java b/core-common/src/main/java/org/apache/kylin/common/util/Triple.java
new file mode 100644
index 0000000..6495332
--- /dev/null
+++ b/core-common/src/main/java/org/apache/kylin/common/util/Triple.java
@@ -0,0 +1,95 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.kylin.common.util;
+
+/**
+ * Utility class to manage a triple. Copied from org.apache.hadoop.hbase.util.Pair
+ */
+public class Triple<A, B, C> {
+    private A first;
+    private B second;
+    private C third;
+
+    public Triple(A first, B second, C third) {
+        this.first = first;
+        this.second = second;
+        this.third = third;
+    }
+
+    // ctor cannot infer types w/o warning but a method can.
+    public static <A, B, C> Triple<A, B, C> create(A first, B second, C third) {
+        return new Triple<A, B, C>(first, second, third);
+    }
+
+    public int hashCode() {
+        int hashFirst = (first != null ? first.hashCode() : 0);
+        int hashSecond = (second != null ? second.hashCode() : 0);
+        int hashThird = (third != null ? third.hashCode() : 0);
+
+        return (hashFirst >> 1) ^ hashSecond ^ (hashThird << 1);
+    }
+
+    public boolean equals(Object obj) {
+        if (!(obj instanceof Triple)) {
+            return false;
+        }
+
+        Triple<?, ?, ?> otherTriple = (Triple<?, ?, ?>) obj;
+
+        if (first != otherTriple.first && (first != null && !(first.equals(otherTriple.first))))
+            return false;
+        if (second != otherTriple.second && (second != null && !(second.equals(otherTriple.second))))
+            return false;
+        if (third != otherTriple.third && (third != null && !(third.equals(otherTriple.third))))
+            return false;
+
+        return true;
+    }
+
+    public String toString() {
+        return "(" + first + ", " + second + "," + third + " )";
+    }
+
+    public A getFirst() {
+        return first;
+    }
+
+    public void setFirst(A first) {
+        this.first = first;
+    }
+
+    public B getSecond() {
+        return second;
+    }
+
+    public void setSecond(B second) {
+        this.second = second;
+    }
+
+    public C getThird() {
+        return third;
+    }
+
+    public void setThird(C third) {
+        this.third = third;
+    }
+}
+
+
+
diff --git a/kylin-it/src/test/resources/query/sql/query00.sql b/kylin-it/src/test/resources/query/sql/query00.sql
index 6e4d94b..a0a1e52 100644
--- a/kylin-it/src/test/resources/query/sql/query00.sql
+++ b/kylin-it/src/test/resources/query/sql/query00.sql
@@ -20,3 +20,4 @@ select lstg_format_name, sum(price) as GMV
  from test_kylin_fact 
  where lstg_format_name='FP-GTC' 
  group by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query01.sql b/kylin-it/src/test/resources/query/sql/query01.sql
index 9ed1db3..1f40ff5 100644
--- a/kylin-it/src/test/resources/query/sql/query01.sql
+++ b/kylin-it/src/test/resources/query/sql/query01.sql
@@ -18,3 +18,4 @@
 
 select LSTG_FORMAT_NAME,slr_segment_cd ,sum(price) as GMV, count(1) as TRANS_CNT from test_kylin_fact 
  group by LSTG_FORMAT_NAME ,slr_segment_cd
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query02.sql b/kylin-it/src/test/resources/query/sql/query02.sql
index 8d27c93..77cebc8 100644
--- a/kylin-it/src/test/resources/query/sql/query02.sql
+++ b/kylin-it/src/test/resources/query/sql/query02.sql
@@ -17,3 +17,4 @@
 --
 
 select sum(price) as GMV, count(1) as TRANS_CNT from test_kylin_fact 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query03.sql b/kylin-it/src/test/resources/query/sql/query03.sql
index a605594..0a2d8db 100644
--- a/kylin-it/src/test/resources/query/sql/query03.sql
+++ b/kylin-it/src/test/resources/query/sql/query03.sql
@@ -18,3 +18,4 @@
 
 select test_kylin_fact.lstg_format_name, sum(price) as GMV, count(*) as TRANS_CNT from test_kylin_fact 
  group by test_kylin_fact.lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query04.sql b/kylin-it/src/test/resources/query/sql/query04.sql
index a3672f5..55c44be 100644
--- a/kylin-it/src/test/resources/query/sql/query04.sql
+++ b/kylin-it/src/test/resources/query/sql/query04.sql
@@ -19,3 +19,4 @@
 select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV 
  , count(*) as TRANS_CNT from test_kylin_fact 
  group by test_kylin_fact.lstg_format_name having sum(price)>5000 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query05.sql b/kylin-it/src/test/resources/query/sql/query05.sql
index 512356a..6144a7d 100644
--- a/kylin-it/src/test/resources/query/sql/query05.sql
+++ b/kylin-it/src/test/resources/query/sql/query05.sql
@@ -20,3 +20,4 @@ select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV
  , count(*) as TRANS_CNT from test_kylin_fact 
  where test_kylin_fact.lstg_format_name is null 
  group by test_kylin_fact.lstg_format_name having sum(price)>5000 and count(*)>72 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query06.sql b/kylin-it/src/test/resources/query/sql/query06.sql
index de99c4f..462cf8f 100644
--- a/kylin-it/src/test/resources/query/sql/query06.sql
+++ b/kylin-it/src/test/resources/query/sql/query06.sql
@@ -21,3 +21,4 @@ select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV
  where test_kylin_fact.lstg_format_name is not null 
  group by test_kylin_fact.lstg_format_name 
  having sum(price)>5000 or count(*)>20 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query07.sql b/kylin-it/src/test/resources/query/sql/query07.sql
index 0c27d98..41bbb96 100644
--- a/kylin-it/src/test/resources/query/sql/query07.sql
+++ b/kylin-it/src/test/resources/query/sql/query07.sql
@@ -20,3 +20,4 @@ select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV
  , count(*) as TRANS_CNT from test_kylin_fact 
  where test_kylin_fact.lstg_format_name='FP-GTC' 
  group by test_kylin_fact.lstg_format_name having sum(price)>5000 or count(*)>20 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query08.sql b/kylin-it/src/test/resources/query/sql/query08.sql
index 7a31541..47c1718 100644
--- a/kylin-it/src/test/resources/query/sql/query08.sql
+++ b/kylin-it/src/test/resources/query/sql/query08.sql
@@ -20,3 +20,4 @@ select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV
  , count(*) as TRANS_CNT from test_kylin_fact 
  where not (test_kylin_fact.lstg_format_name='FP-GTC') 
  group by test_kylin_fact.lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query09.sql b/kylin-it/src/test/resources/query/sql/query09.sql
index d13f8c8..0fbb7b1 100644
--- a/kylin-it/src/test/resources/query/sql/query09.sql
+++ b/kylin-it/src/test/resources/query/sql/query09.sql
@@ -25,3 +25,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  group by test_cal_dt.week_beg_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query10.sql b/kylin-it/src/test/resources/query/sql/query10.sql
index ad86086..93541c7 100644
--- a/kylin-it/src/test/resources/query/sql/query10.sql
+++ b/kylin-it/src/test/resources/query/sql/query10.sql
@@ -28,3 +28,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  where test_kylin_fact.lstg_format_name='FP-GTC' 
  and test_cal_dt.week_beg_dt between '2013-05-01' and DATE '2013-08-01'
  group by test_cal_dt.week_beg_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query100.sql b/kylin-it/src/test/resources/query/sql/query100.sql
index a2b0d1b..af37e69 100644
--- a/kylin-it/src/test/resources/query/sql/query100.sql
+++ b/kylin-it/src/test/resources/query/sql/query100.sql
@@ -17,4 +17,4 @@
 --
 
 select count(*) as cnt from test_kylin_fact
-where lstg_format_name>='AAAA' and 'BBBB'>=lstg_format_name
\ No newline at end of file
+where lstg_format_name>='AAAA' and 'BBBB'>=lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query101.sql b/kylin-it/src/test/resources/query/sql/query101.sql
index 765d26d..955eeb7 100644
--- a/kylin-it/src/test/resources/query/sql/query101.sql
+++ b/kylin-it/src/test/resources/query/sql/query101.sql
@@ -28,4 +28,4 @@ select meta_categ_name, count(1) as cnt, sum(price) as GMV
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
 
  where not ( meta_categ_name not in ('', 'a','Computers') )
- group by meta_categ_name 
\ No newline at end of file
+ group by meta_categ_name ;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query102.sql b/kylin-it/src/test/resources/query/sql/query102.sql
index 6073c98..ecc116d 100644
--- a/kylin-it/src/test/resources/query/sql/query102.sql
+++ b/kylin-it/src/test/resources/query/sql/query102.sql
@@ -28,4 +28,4 @@ select meta_categ_name, count(1) as cnt, sum(price) as GMV
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
 
  where not ( meta_categ_name not in ('', 'a','Computers') and meta_categ_name not in ('Crafts','Computers'))
- group by meta_categ_name 
\ No newline at end of file
+ group by meta_categ_name ;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query103.sql b/kylin-it/src/test/resources/query/sql/query103.sql
index 6c8ce9e..ceabbfc 100644
--- a/kylin-it/src/test/resources/query/sql/query103.sql
+++ b/kylin-it/src/test/resources/query/sql/query103.sql
@@ -28,4 +28,4 @@ select meta_categ_name, count(1) as cnt, sum(price) as GMV
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
 
  where not ( meta_categ_name not in ('', 'a','Computers') or meta_categ_name not in ('Crafts','Computers'))
- group by meta_categ_name 
\ No newline at end of file
+ group by meta_categ_name ;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query104.sql b/kylin-it/src/test/resources/query/sql/query104.sql
index bb85664..7c80c96 100644
--- a/kylin-it/src/test/resources/query/sql/query104.sql
+++ b/kylin-it/src/test/resources/query/sql/query104.sql
@@ -28,4 +28,4 @@ select concat(meta_categ_name, lstg_format_name) as c1, concat(meta_categ_name,
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
 
  where not ( meta_categ_name not in ('', 'a','Computers') or meta_categ_name not in ('Crafts','Computers'))
- group by concat(meta_categ_name, lstg_format_name), concat(meta_categ_name, 'CONST'), concat(meta_categ_name, concat(test_sites.site_name, lstg_format_name))
\ No newline at end of file
+ group by concat(meta_categ_name, lstg_format_name), concat(meta_categ_name, 'CONST'), concat(meta_categ_name, concat(test_sites.site_name, lstg_format_name));{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":79872}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query105.sql b/kylin-it/src/test/resources/query/sql/query105.sql
index a467b65..bf45e00 100644
--- a/kylin-it/src/test/resources/query/sql/query105.sql
+++ b/kylin-it/src/test/resources/query/sql/query105.sql
@@ -24,3 +24,4 @@ select fact.lstg_format_name from
  
  order by CASE WHEN fact.lstg_format_name IS NULL THEN 'sdf' ELSE fact.lstg_format_name END 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query106.sql b/kylin-it/src/test/resources/query/sql/query106.sql
index d8faaaf..038c674 100644
--- a/kylin-it/src/test/resources/query/sql/query106.sql
+++ b/kylin-it/src/test/resources/query/sql/query106.sql
@@ -99,3 +99,4 @@ where ( META_CATEG_NAME IN ('jenny','esrzongguan','Baby')
                        
                        
                        )
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query107.sql b/kylin-it/src/test/resources/query/sql/query107.sql
index 4836f4c..8ddeeb3 100644
--- a/kylin-it/src/test/resources/query/sql/query107.sql
+++ b/kylin-it/src/test/resources/query/sql/query107.sql
@@ -100,3 +100,4 @@ where ( META_CATEG_NAME IN ('jenny','esrzongguan','Baby')
                        
                        
                        )
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query108.sql b/kylin-it/src/test/resources/query/sql/query108.sql
index 10d103a..5484d4f 100644
--- a/kylin-it/src/test/resources/query/sql/query108.sql
+++ b/kylin-it/src/test/resources/query/sql/query108.sql
@@ -40,3 +40,4 @@ SELECT
  ,test_category_groupings.categ_lvl3_name 
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query109.sql b/kylin-it/src/test/resources/query/sql/query109.sql
index 4df8285..c36d735 100644
--- a/kylin-it/src/test/resources/query/sql/query109.sql
+++ b/kylin-it/src/test/resources/query/sql/query109.sql
@@ -24,3 +24,4 @@ select sum(price) as GMV, count(*) as TRANS_CNT  FROM test_kylin_fact
  AND test_kylin_fact.lstg_site_id = test_category_groupings.site_id
 where test_kylin_fact.cal_dt < DATE '2012-05-01' or test_kylin_fact.cal_dt > DATE '2013-05-01'
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query11.sql b/kylin-it/src/test/resources/query/sql/query11.sql
index e431a63..d22fa6e 100644
--- a/kylin-it/src/test/resources/query/sql/query11.sql
+++ b/kylin-it/src/test/resources/query/sql/query11.sql
@@ -28,3 +28,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  where test_cal_dt.week_beg_dt between DATE '2013-05-01' and DATE '2013-08-01' 
  group by test_kylin_fact.lstg_format_name, test_cal_dt.week_beg_dt 
  having sum(price)>500 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query110.sql b/kylin-it/src/test/resources/query/sql/query110.sql
index 07cd3b2..4b0fe7b 100644
--- a/kylin-it/src/test/resources/query/sql/query110.sql
+++ b/kylin-it/src/test/resources/query/sql/query110.sql
@@ -55,4 +55,4 @@ SELECT  TEST_KYLIN_FACT.CAL_DT as TEST_KYLIN_FACT_CAL_DT,
         ON SELLER_ACCOUNT.ACCOUNT_COUNTRY = SELLER_COUNTRY.COUNTRY
         LEFT JOIN "DEFAULT".TEST_COUNTRY as BUYER_COUNTRY
         ON BUYER_ACCOUNT.ACCOUNT_COUNTRY = BUYER_COUNTRY.COUNTRY
-        WHERE 1=1
\ No newline at end of file
+        WHERE 1=1;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query112.sql b/kylin-it/src/test/resources/query/sql/query112.sql
index efd0d88..05e99ec 100644
--- a/kylin-it/src/test/resources/query/sql/query112.sql
+++ b/kylin-it/src/test/resources/query/sql/query112.sql
@@ -26,4 +26,4 @@ FROM test_kylin_fact
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
 WHERE test_cal_dt.WEEK_BEG_DT >= '2001-09-09'
  AND test_cal_dt.WEEK_BEG_DT <= '2018-05-16'
- 
\ No newline at end of file
+ ;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query113.sql b/kylin-it/src/test/resources/query/sql/query113.sql
index 7f5e92b..e7e4838 100644
--- a/kylin-it/src/test/resources/query/sql/query113.sql
+++ b/kylin-it/src/test/resources/query/sql/query113.sql
@@ -26,4 +26,4 @@ FROM test_kylin_fact
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
 WHERE test_cal_dt.WEEK_BEG_DT >= '2001-09-09'
  AND test_cal_dt.WEEK_BEG_DT <= '2018-05-16'
- 
\ No newline at end of file
+ ;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query114.sql b/kylin-it/src/test/resources/query/sql/query114.sql
index 0e802f7..08269cc 100644
--- a/kylin-it/src/test/resources/query/sql/query114.sql
+++ b/kylin-it/src/test/resources/query/sql/query114.sql
@@ -25,4 +25,4 @@ FROM test_kylin_fact
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
 WHERE test_cal_dt.WEEK_BEG_DT >= '2001-09-09'
- AND test_cal_dt.WEEK_BEG_DT <= '2018-05-16'
\ No newline at end of file
+ AND test_cal_dt.WEEK_BEG_DT <= '2018-05-16';{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query12.sql b/kylin-it/src/test/resources/query/sql/query12.sql
index 012ecfc..5f5f216 100644
--- a/kylin-it/src/test/resources/query/sql/query12.sql
+++ b/kylin-it/src/test/resources/query/sql/query12.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_cal_dt.week_beg_dt >= DATE '2013-02-10' 
  group by test_kylin_fact.lstg_format_name, test_cal_dt.week_beg_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query13.sql b/kylin-it/src/test/resources/query/sql/query13.sql
index 7d1c481..12d4ecb 100644
--- a/kylin-it/src/test/resources/query/sql/query13.sql
+++ b/kylin-it/src/test/resources/query/sql/query13.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.lstg_format_name='FP-GTC' 
  and test_cal_dt.week_beg_dt between DATE '2013-05-01' and DATE '2013-08-01' 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query14.sql b/kylin-it/src/test/resources/query/sql/query14.sql
index 9cca8f5..772826f 100644
--- a/kylin-it/src/test/resources/query/sql/query14.sql
+++ b/kylin-it/src/test/resources/query/sql/query14.sql
@@ -34,3 +34,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ,test_category_groupings.meta_categ_name 
  ,test_category_groupings.categ_lvl2_name 
  ,test_category_groupings.categ_lvl3_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query15.sql b/kylin-it/src/test/resources/query/sql/query15.sql
index b189de30..8eda90f 100644
--- a/kylin-it/src/test/resources/query/sql/query15.sql
+++ b/kylin-it/src/test/resources/query/sql/query15.sql
@@ -30,3 +30,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  group by test_cal_dt.week_beg_dt 
  ,test_category_groupings.meta_categ_name 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":327680}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query16.sql b/kylin-it/src/test/resources/query/sql/query16.sql
index 2c64347..d9101ea 100644
--- a/kylin-it/src/test/resources/query/sql/query16.sql
+++ b/kylin-it/src/test/resources/query/sql/query16.sql
@@ -33,3 +33,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ,test_category_groupings.meta_categ_name 
  ,test_category_groupings.categ_lvl2_name 
  ,test_category_groupings.categ_lvl3_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query17.sql b/kylin-it/src/test/resources/query/sql/query17.sql
index c6cb4e5..7bedf4a 100644
--- a/kylin-it/src/test/resources/query/sql/query17.sql
+++ b/kylin-it/src/test/resources/query/sql/query17.sql
@@ -36,3 +36,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ,test_category_groupings.categ_lvl2_name 
  ,test_category_groupings.categ_lvl3_name 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query18.sql b/kylin-it/src/test/resources/query/sql/query18.sql
index 30939be..cfbfb53 100644
--- a/kylin-it/src/test/resources/query/sql/query18.sql
+++ b/kylin-it/src/test/resources/query/sql/query18.sql
@@ -32,3 +32,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  group by test_cal_dt.week_beg_dt 
  ,test_category_groupings.meta_categ_name 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":360448}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query19.sql b/kylin-it/src/test/resources/query/sql/query19.sql
index c6cb4e5..7bedf4a 100644
--- a/kylin-it/src/test/resources/query/sql/query19.sql
+++ b/kylin-it/src/test/resources/query/sql/query19.sql
@@ -36,3 +36,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ,test_category_groupings.categ_lvl2_name 
  ,test_category_groupings.categ_lvl3_name 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query20.sql b/kylin-it/src/test/resources/query/sql/query20.sql
index 5958037..5e6c001 100644
--- a/kylin-it/src/test/resources/query/sql/query20.sql
+++ b/kylin-it/src/test/resources/query/sql/query20.sql
@@ -32,3 +32,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  group by test_cal_dt.week_beg_dt 
  ,test_category_groupings.meta_categ_name 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query21.sql b/kylin-it/src/test/resources/query/sql/query21.sql
index 5a7c446..99d3fe6 100644
--- a/kylin-it/src/test/resources/query/sql/query21.sql
+++ b/kylin-it/src/test/resources/query/sql/query21.sql
@@ -38,3 +38,4 @@ SELECT
  ,test_category_groupings.categ_lvl3_name 
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query22.sql b/kylin-it/src/test/resources/query/sql/query22.sql
index 8aa7f66..f602fa7 100644
--- a/kylin-it/src/test/resources/query/sql/query22.sql
+++ b/kylin-it/src/test/resources/query/sql/query22.sql
@@ -40,3 +40,4 @@ SELECT
  ,test_category_groupings.categ_lvl3_name 
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query23.sql b/kylin-it/src/test/resources/query/sql/query23.sql
index 6d4e5cb..760a283 100644
--- a/kylin-it/src/test/resources/query/sql/query23.sql
+++ b/kylin-it/src/test/resources/query/sql/query23.sql
@@ -39,3 +39,4 @@ SELECT
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query24.sql b/kylin-it/src/test/resources/query/sql/query24.sql
index 22c376e..7cebd90 100644
--- a/kylin-it/src/test/resources/query/sql/query24.sql
+++ b/kylin-it/src/test/resources/query/sql/query24.sql
@@ -43,3 +43,4 @@ SELECT
  ,test_sites.site_name 
  ,test_seller_type_dim.seller_type_desc 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query25.sql b/kylin-it/src/test/resources/query/sql/query25.sql
index fe19065..ca98acf 100644
--- a/kylin-it/src/test/resources/query/sql/query25.sql
+++ b/kylin-it/src/test/resources/query/sql/query25.sql
@@ -44,3 +44,4 @@ SELECT
  ,test_sites.site_name 
  ,test_seller_type_dim.seller_type_desc 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query26.sql b/kylin-it/src/test/resources/query/sql/query26.sql
index c908c6c..ceba7f1 100644
--- a/kylin-it/src/test/resources/query/sql/query26.sql
+++ b/kylin-it/src/test/resources/query/sql/query26.sql
@@ -46,3 +46,4 @@ SELECT
  ,test_sites.site_name 
  ,test_seller_type_dim.seller_type_desc 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query27.sql b/kylin-it/src/test/resources/query/sql/query27.sql
index 0c204ed..9026cb9 100644
--- a/kylin-it/src/test/resources/query/sql/query27.sql
+++ b/kylin-it/src/test/resources/query/sql/query27.sql
@@ -45,3 +45,4 @@ SELECT
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
  ,test_seller_type_dim.seller_type_desc 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query28.sql b/kylin-it/src/test/resources/query/sql/query28.sql
index 58a0b8e..ee2192c 100644
--- a/kylin-it/src/test/resources/query/sql/query28.sql
+++ b/kylin-it/src/test/resources/query/sql/query28.sql
@@ -28,3 +28,4 @@ SELECT
  ON test_kylin_fact.lstg_site_id = test_sites.site_id 
  inner JOIN edw.test_seller_type_dim as test_seller_type_dim 
  ON test_kylin_fact.slr_segment_cd = test_seller_type_dim.seller_type_cd 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query29.sql b/kylin-it/src/test/resources/query/sql/query29.sql
index b2e9c9d..42f8dca 100644
--- a/kylin-it/src/test/resources/query/sql/query29.sql
+++ b/kylin-it/src/test/resources/query/sql/query29.sql
@@ -30,3 +30,4 @@ SELECT
  group by test_cal_dt.week_beg_dt 
  ,test_category_groupings.meta_categ_name 
  ,test_category_groupings.categ_lvl2_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":360448}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query30.sql b/kylin-it/src/test/resources/query/sql/query30.sql
index 4d7011f..1ce1aef 100644
--- a/kylin-it/src/test/resources/query/sql/query30.sql
+++ b/kylin-it/src/test/resources/query/sql/query30.sql
@@ -17,3 +17,4 @@
 --
 
 select sum(price) as GMV, count(1) as TRANS_CNT ,  sum(test_kylin_fact.item_count) as total_items from test_kylin_fact limit 50 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query31.sql b/kylin-it/src/test/resources/query/sql/query31.sql
index faa7863..c2726a8 100644
--- a/kylin-it/src/test/resources/query/sql/query31.sql
+++ b/kylin-it/src/test/resources/query/sql/query31.sql
@@ -38,3 +38,4 @@ SELECT
  ,test_category_groupings.categ_lvl3_name 
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query32.sql b/kylin-it/src/test/resources/query/sql/query32.sql
index c389cbe..06b5e74 100644
--- a/kylin-it/src/test/resources/query/sql/query32.sql
+++ b/kylin-it/src/test/resources/query/sql/query32.sql
@@ -37,3 +37,4 @@ SELECT
  ,test_category_groupings.categ_lvl3_name 
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query33.sql b/kylin-it/src/test/resources/query/sql/query33.sql
index ff56aee..d160f8f 100644
--- a/kylin-it/src/test/resources/query/sql/query33.sql
+++ b/kylin-it/src/test/resources/query/sql/query33.sql
@@ -41,3 +41,4 @@ SELECT
  ,test_category_groupings.categ_lvl3_name 
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query34.sql b/kylin-it/src/test/resources/query/sql/query34.sql
index 821df2c..444ba40 100644
--- a/kylin-it/src/test/resources/query/sql/query34.sql
+++ b/kylin-it/src/test/resources/query/sql/query34.sql
@@ -39,3 +39,4 @@ SELECT
  ,test_category_groupings.categ_lvl3_name 
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query35.sql b/kylin-it/src/test/resources/query/sql/query35.sql
index c744f73..8e34257 100644
--- a/kylin-it/src/test/resources/query/sql/query35.sql
+++ b/kylin-it/src/test/resources/query/sql/query35.sql
@@ -39,3 +39,4 @@ SELECT
  ,test_category_groupings.categ_lvl3_name 
  ,test_kylin_fact.lstg_format_name 
  ,test_sites.site_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query36.sql b/kylin-it/src/test/resources/query/sql/query36.sql
index 74b8ede..cbce9f1 100644
--- a/kylin-it/src/test/resources/query/sql/query36.sql
+++ b/kylin-it/src/test/resources/query/sql/query36.sql
@@ -32,3 +32,4 @@ SELECT
  where test_kylin_fact.seller_id = 10000002 or test_kylin_fact.lstg_format_name = 'FP-non GTC' 
  group by 
  test_category_groupings.meta_categ_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query37.sql b/kylin-it/src/test/resources/query/sql/query37.sql
index eebd515..e0b5099 100644
--- a/kylin-it/src/test/resources/query/sql/query37.sql
+++ b/kylin-it/src/test/resources/query/sql/query37.sql
@@ -34,3 +34,4 @@ select test_cal_dt.week_beg_dt, sum(test_kylin_fact.price) as GMV
  (test_cal_dt.week_beg_dt between DATE '2013-05-20' and DATE '2013-05-21') 
  ) 
  group by test_cal_dt.week_beg_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query38.sql b/kylin-it/src/test/resources/query/sql/query38.sql
index 8a832f3..581e652 100644
--- a/kylin-it/src/test/resources/query/sql/query38.sql
+++ b/kylin-it/src/test/resources/query/sql/query38.sql
@@ -20,3 +20,4 @@ select lstg_format_name, sum(price) as GMV
  from test_kylin_fact 
  where lstg_format_name not in ('FP-GTC', 'ABIN') 
  group by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query39.sql b/kylin-it/src/test/resources/query/sql/query39.sql
index 75155ec..eef5e50 100644
--- a/kylin-it/src/test/resources/query/sql/query39.sql
+++ b/kylin-it/src/test/resources/query/sql/query39.sql
@@ -18,3 +18,4 @@
 
 select sum(price) as GMV 
  from test_kylin_fact 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query40.sql b/kylin-it/src/test/resources/query/sql/query40.sql
index a6705b5..005ab61 100644
--- a/kylin-it/src/test/resources/query/sql/query40.sql
+++ b/kylin-it/src/test/resources/query/sql/query40.sql
@@ -20,3 +20,4 @@ select cal_dt, lstg_format_name, sum(price) as GMV , sum(test_kylin_fact.item_co
  from test_kylin_fact 
  where cal_dt between date '2013-05-06' and date '2013-07-31' 
  group by cal_dt, lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query41.sql b/kylin-it/src/test/resources/query/sql/query41.sql
index 8b4d566..5c53bdf 100644
--- a/kylin-it/src/test/resources/query/sql/query41.sql
+++ b/kylin-it/src/test/resources/query/sql/query41.sql
@@ -28,3 +28,4 @@ SELECT
  group by 
  test_category_groupings.meta_categ_name 
  ,test_category_groupings.categ_lvl2_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":98304}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query42.sql b/kylin-it/src/test/resources/query/sql/query42.sql
index 3364a2a..e3296f0 100644
--- a/kylin-it/src/test/resources/query/sql/query42.sql
+++ b/kylin-it/src/test/resources/query/sql/query42.sql
@@ -25,3 +25,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  group by test_cal_dt.cal_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query43.sql b/kylin-it/src/test/resources/query/sql/query43.sql
index 1125699..4ae4441 100644
--- a/kylin-it/src/test/resources/query/sql/query43.sql
+++ b/kylin-it/src/test/resources/query/sql/query43.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  where test_kylin_fact.lstg_format_name='FP-GTC' 
  and test_cal_dt.week_beg_dt between DATE '2013-05-01' and DATE '2013-08-01' 
  group by test_cal_dt.cal_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query44.sql b/kylin-it/src/test/resources/query/sql/query44.sql
index ae4f774..639004e 100644
--- a/kylin-it/src/test/resources/query/sql/query44.sql
+++ b/kylin-it/src/test/resources/query/sql/query44.sql
@@ -29,3 +29,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  group by 
  test_category_groupings.meta_categ_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query49.sql b/kylin-it/src/test/resources/query/sql/query49.sql
index a28beb6..705e3f3 100644
--- a/kylin-it/src/test/resources/query/sql/query49.sql
+++ b/kylin-it/src/test/resources/query/sql/query49.sql
@@ -34,3 +34,4 @@ SELECT
  ,test_category_groupings.categ_lvl2_name 
  ,test_category_groupings.categ_lvl3_name 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query50.sql b/kylin-it/src/test/resources/query/sql/query50.sql
index 286e2df..687d0c7 100644
--- a/kylin-it/src/test/resources/query/sql/query50.sql
+++ b/kylin-it/src/test/resources/query/sql/query50.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where  1 < 3
  group by test_kylin_fact.lstg_format_name, test_cal_dt.week_beg_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query51.sql b/kylin-it/src/test/resources/query/sql/query51.sql
index 82cf289..a050538 100644
--- a/kylin-it/src/test/resources/query/sql/query51.sql
+++ b/kylin-it/src/test/resources/query/sql/query51.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where  DATE '2013-03-24'  <= test_cal_dt.week_beg_dt
  group by test_kylin_fact.lstg_format_name, test_cal_dt.week_beg_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query52.sql b/kylin-it/src/test/resources/query/sql/query52.sql
index 192f6b9..d3efe27 100644
--- a/kylin-it/src/test/resources/query/sql/query52.sql
+++ b/kylin-it/src/test/resources/query/sql/query52.sql
@@ -20,3 +20,4 @@ select lstg_format_name, sum(price) as GMV
  from test_kylin_fact 
  where test_kylin_fact.seller_id in ( 10000002, 10000003, 10000004,10000005,10000006,10000008,10000009,10000001,10000010,10000011)
  group by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query53.sql b/kylin-it/src/test/resources/query/sql/query53.sql
index b835ec0..f2c44df 100644
--- a/kylin-it/src/test/resources/query/sql/query53.sql
+++ b/kylin-it/src/test/resources/query/sql/query53.sql
@@ -22,3 +22,4 @@ from test_kylin_fact
 where DATE '2012-09-01' <= test_kylin_fact.cal_dt   and  test_kylin_fact.seller_id = 10000002
  group by test_kylin_fact.cal_dt,
 test_kylin_fact.seller_id
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":1310735}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query54.sql b/kylin-it/src/test/resources/query/sql/query54.sql
index b9532fc..6f10423 100644
--- a/kylin-it/src/test/resources/query/sql/query54.sql
+++ b/kylin-it/src/test/resources/query/sql/query54.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where 1 <> 1
  group by test_kylin_fact.lstg_format_name, test_cal_dt.week_beg_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query55.sql b/kylin-it/src/test/resources/query/sql/query55.sql
index d0f391f..99c92b2 100644
--- a/kylin-it/src/test/resources/query/sql/query55.sql
+++ b/kylin-it/src/test/resources/query/sql/query55.sql
@@ -28,3 +28,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  where
  extract(DAY from test_cal_dt.cal_dt) = 12
  group by test_cal_dt.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query56.sql b/kylin-it/src/test/resources/query/sql/query56.sql
index 08e8ec3..3576d27 100644
--- a/kylin-it/src/test/resources/query/sql/query56.sql
+++ b/kylin-it/src/test/resources/query/sql/query56.sql
@@ -28,3 +28,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  where
  extract(MONTH from test_cal_dt.week_beg_dt) = 12
  group by test_cal_dt.week_beg_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query57.sql b/kylin-it/src/test/resources/query/sql/query57.sql
index 386d248..80832ac 100644
--- a/kylin-it/src/test/resources/query/sql/query57.sql
+++ b/kylin-it/src/test/resources/query/sql/query57.sql
@@ -28,3 +28,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  where
  (test_kylin_fact.lstg_format_name='FP-GTC')  and extract(MONTH from test_cal_dt.week_beg_dt) = 12
  group by test_cal_dt.week_beg_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query58.sql b/kylin-it/src/test/resources/query/sql/query58.sql
index 0ddeff9..b1f785d 100644
--- a/kylin-it/src/test/resources/query/sql/query58.sql
+++ b/kylin-it/src/test/resources/query/sql/query58.sql
@@ -28,3 +28,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  where
  (test_kylin_fact.lstg_format_name='FP-GTC')  and extract(MONTH from test_cal_dt.week_beg_dt) = 12
  group by test_kylin_fact.lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query59.sql b/kylin-it/src/test/resources/query/sql/query59.sql
index 0731854..d37a1b9 100644
--- a/kylin-it/src/test/resources/query/sql/query59.sql
+++ b/kylin-it/src/test/resources/query/sql/query59.sql
@@ -17,3 +17,4 @@
 --
 
 select sum(price) as GVM,lstg_format_name from test_kylin_fact group by lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query60.sql b/kylin-it/src/test/resources/query/sql/query60.sql
index 9881637..df74bff 100644
--- a/kylin-it/src/test/resources/query/sql/query60.sql
+++ b/kylin-it/src/test/resources/query/sql/query60.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
 group by test_kylin_fact.cal_dt 
 order by 2 desc 
 limit 3
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query61.sql b/kylin-it/src/test/resources/query/sql/query61.sql
index 183fd00..35d58cb 100644
--- a/kylin-it/src/test/resources/query/sql/query61.sql
+++ b/kylin-it/src/test/resources/query/sql/query61.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
 group by test_kylin_fact.cal_dt 
 order by 1 desc 
 limit 4
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query62.sql b/kylin-it/src/test/resources/query/sql/query62.sql
index 7f195e1..88366cc 100644
--- a/kylin-it/src/test/resources/query/sql/query62.sql
+++ b/kylin-it/src/test/resources/query/sql/query62.sql
@@ -19,3 +19,4 @@
 select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV , min(cal_dt) as min_cal_dt
  , count(*) as TRANS_CNT from test_kylin_fact
  group by test_kylin_fact.lstg_format_name having sum(price)>5000 and count(*)>72
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query63.sql b/kylin-it/src/test/resources/query/sql/query63.sql
index 687cee7..6c2c62c 100644
--- a/kylin-it/src/test/resources/query/sql/query63.sql
+++ b/kylin-it/src/test/resources/query/sql/query63.sql
@@ -18,3 +18,4 @@
 
 select min(cal_dt) as min_cal_dt
  from test_kylin_fact
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query64.sql b/kylin-it/src/test/resources/query/sql/query64.sql
index a7f877f..5719ab9 100644
--- a/kylin-it/src/test/resources/query/sql/query64.sql
+++ b/kylin-it/src/test/resources/query/sql/query64.sql
@@ -19,3 +19,4 @@
  select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV , min(cal_dt) as min_cal_dt
  , count(*) as TRANS_CNT from test_kylin_fact
  group by test_kylin_fact.lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query65.sql b/kylin-it/src/test/resources/query/sql/query65.sql
index e20393b..97b9d8a 100644
--- a/kylin-it/src/test/resources/query/sql/query65.sql
+++ b/kylin-it/src/test/resources/query/sql/query65.sql
@@ -17,3 +17,4 @@
 --
 
 select min(cal_dt) as min_cal_dt, max(cal_dt) as max_cal_dt from test_kylin_fact
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query66.sql b/kylin-it/src/test/resources/query/sql/query66.sql
index d9f14ee..5f3e7fc 100644
--- a/kylin-it/src/test/resources/query/sql/query66.sql
+++ b/kylin-it/src/test/resources/query/sql/query66.sql
@@ -22,3 +22,4 @@ select test_kylin_fact.cal_dt, max(test_kylin_fact.cal_dt) as mmm from test_kyli
  ON test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id AND test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id group by test_kylin_fact.cal_dt order by 2 desc limit 7
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query67.sql b/kylin-it/src/test/resources/query/sql/query67.sql
index e145d72..9d5d5fd 100644
--- a/kylin-it/src/test/resources/query/sql/query67.sql
+++ b/kylin-it/src/test/resources/query/sql/query67.sql
@@ -20,3 +20,4 @@ SELECT (CASE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" WHEN 'Auction' THEN '111' ELSE
   SUM("TEST_KYLIN_FACT"."PRICE") AS "sum_PRICE_ok"
 FROM "TEST_KYLIN_FACT" "TEST_KYLIN_FACT"
 group by (CASE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" WHEN 'Auction' THEN '111' ELSE '222' END)  ORDER BY 1 ASC
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query68.sql b/kylin-it/src/test/resources/query/sql/query68.sql
index 30f9980..6d9c067 100644
--- a/kylin-it/src/test/resources/query/sql/query68.sql
+++ b/kylin-it/src/test/resources/query/sql/query68.sql
@@ -24,3 +24,4 @@ select count(1) as cnt, min(cal_dt) as "mmm",  cal_dt as dt from test_kylin_fact
 
 
 ) t0 on (fact.cal_dt = t0.dt) group by cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query69.sql b/kylin-it/src/test/resources/query/sql/query69.sql
index 40377e3..1d50412 100644
--- a/kylin-it/src/test/resources/query/sql/query69.sql
+++ b/kylin-it/src/test/resources/query/sql/query69.sql
@@ -23,3 +23,4 @@ select lstg_format_name,
  where (CASE WHEN ("TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" IN ('Auction', 'FP-GTC')) THEN 'Auction' ELSE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" END) = 'Auction'
  group by lstg_format_name 
  order by sum(price)
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query70.sql b/kylin-it/src/test/resources/query/sql/query70.sql
index a0aa8b3..5ac4567 100644
--- a/kylin-it/src/test/resources/query/sql/query70.sql
+++ b/kylin-it/src/test/resources/query/sql/query70.sql
@@ -22,3 +22,4 @@ select lstg_format_name,
  from test_kylin_fact 
  where "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" = 'Auction' and (CASE WHEN ("TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" IN ('Auction', 'FP-GTC')) THEN 'Auction' ELSE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" END) = 'Auction'
  group by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query71.sql b/kylin-it/src/test/resources/query/sql/query71.sql
index b3abe3d..e84f913 100644
--- a/kylin-it/src/test/resources/query/sql/query71.sql
+++ b/kylin-it/src/test/resources/query/sql/query71.sql
@@ -22,3 +22,4 @@ select lstg_format_name,
  from test_kylin_fact 
  where "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" in ('Auction', 'ABIN') and (CASE WHEN ("TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" IN ('Auction', 'FP-GTC')) THEN 'Auction' ELSE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" END) = 'Auction'
  group by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query72.sql b/kylin-it/src/test/resources/query/sql/query72.sql
index 7eda4ee..8a3f0c2 100644
--- a/kylin-it/src/test/resources/query/sql/query72.sql
+++ b/kylin-it/src/test/resources/query/sql/query72.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.lstg_format_name='FP-GTC'  or extract(MONTH from test_cal_dt.week_beg_dt) = 12
  group by test_cal_dt.week_beg_dt, test_kylin_fact.lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query73.sql b/kylin-it/src/test/resources/query/sql/query73.sql
index 04c6155..e2d2a86 100644
--- a/kylin-it/src/test/resources/query/sql/query73.sql
+++ b/kylin-it/src/test/resources/query/sql/query73.sql
@@ -17,3 +17,4 @@
 --
 
 select min("t"."s") as min_pr from (select max(price) as "s" from test_kylin_fact group by lstg_format_name) "t"  having (count(1) > 0)
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query74.sql b/kylin-it/src/test/resources/query/sql/query74.sql
index 0949336..42e4ab7 100644
--- a/kylin-it/src/test/resources/query/sql/query74.sql
+++ b/kylin-it/src/test/resources/query/sql/query74.sql
@@ -17,3 +17,4 @@
 --
 
 select min("t"."s") as min_x, max("t"."s") as max_x from (select max(price) as "s" from test_kylin_fact group by lstg_format_name) "t" having ( count(1)  > 0)
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query75.sql b/kylin-it/src/test/resources/query/sql/query75.sql
index ebc8608..15b5e3a 100644
--- a/kylin-it/src/test/resources/query/sql/query75.sql
+++ b/kylin-it/src/test/resources/query/sql/query75.sql
@@ -20,3 +20,4 @@ select lstg_format_name, sum(price) as GMV
  from test_kylin_fact 
  where (NOT ((CASE WHEN (lstg_format_name IS NULL) THEN 1 WHEN NOT (lstg_format_name IS NULL) THEN 0 ELSE NULL END) <> 0))
  group by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query76.sql b/kylin-it/src/test/resources/query/sql/query76.sql
index b6991f7..926ea77 100644
--- a/kylin-it/src/test/resources/query/sql/query76.sql
+++ b/kylin-it/src/test/resources/query/sql/query76.sql
@@ -20,3 +20,4 @@ select lstg_format_name, sum(price) as GMV
  from test_kylin_fact 
  group by lstg_format_name, SLR_SEGMENT_CD
   having SLR_SEGMENT_CD > 0
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query77.sql b/kylin-it/src/test/resources/query/sql/query77.sql
index 18e5240..a47d420 100644
--- a/kylin-it/src/test/resources/query/sql/query77.sql
+++ b/kylin-it/src/test/resources/query/sql/query77.sql
@@ -19,3 +19,4 @@
 select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV
  , count(*) as TRANS_CNT from test_kylin_fact
  group by test_kylin_fact.lstg_format_name having sum(price)>5000 and count(*)>72
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query78.sql b/kylin-it/src/test/resources/query/sql/query78.sql
index da0718a..b6c2870 100644
--- a/kylin-it/src/test/resources/query/sql/query78.sql
+++ b/kylin-it/src/test/resources/query/sql/query78.sql
@@ -20,3 +20,4 @@ select sum(PRICE) as GMV, LSTG_FORMAT_NAME as FORMAT_NAME
 from test_kylin_fact
 where (LSTG_FORMAT_NAME in ('ABIN')) or  (LSTG_FORMAT_NAME>='FP-GTC' and LSTG_FORMAT_NAME<='Others')
 group by LSTG_FORMAT_NAME
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query79.sql b/kylin-it/src/test/resources/query/sql/query79.sql
index 76b7928..f288e1e 100644
--- a/kylin-it/src/test/resources/query/sql/query79.sql
+++ b/kylin-it/src/test/resources/query/sql/query79.sql
@@ -17,3 +17,4 @@
 --
 
 select max(cal_dt) as cnt from test_kylin_fact
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query80.sql b/kylin-it/src/test/resources/query/sql/query80.sql
index 0e2dbb4..e23abb2 100644
--- a/kylin-it/src/test/resources/query/sql/query80.sql
+++ b/kylin-it/src/test/resources/query/sql/query80.sql
@@ -26,3 +26,4 @@ SELECT
  inner JOIN test_category_groupings
  ON test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id
  AND test_kylin_fact.lstg_site_id = test_category_groupings.site_id 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query83.sql b/kylin-it/src/test/resources/query/sql/query83.sql
index 1fbbd33..5de5a08 100644
--- a/kylin-it/src/test/resources/query/sql/query83.sql
+++ b/kylin-it/src/test/resources/query/sql/query83.sql
@@ -30,4 +30,4 @@
  where test_kylin_fact.lstg_format_name='FP-GTC' 
  and test_cal_dt.week_beg_dt between DATE '2013-05-01' and DATE '2013-08-01' 
  and test_kylin_fact.cal_dt between DATE '2013-06-01' and DATE '2013-09-01' 
- group by test_cal_dt.week_beg_dt 
\ No newline at end of file
+ group by test_cal_dt.week_beg_dt ;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query84.sql b/kylin-it/src/test/resources/query/sql/query84.sql
index 2560465..cf32515 100644
--- a/kylin-it/src/test/resources/query/sql/query84.sql
+++ b/kylin-it/src/test/resources/query/sql/query84.sql
@@ -30,4 +30,4 @@
  where test_kylin_fact.lstg_format_name='FP-GTC' 
  and test_cal_dt.week_beg_dt between DATE '2013-05-01' and DATE '2013-08-01' 
  and test_cal_dt.cal_dt between DATE '2013-06-01' and DATE '2013-09-01' 
- group by test_cal_dt.week_beg_dt 
\ No newline at end of file
+ group by test_cal_dt.week_beg_dt ;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query85.sql b/kylin-it/src/test/resources/query/sql/query85.sql
index 1a51a02..42ee1ea 100644
--- a/kylin-it/src/test/resources/query/sql/query85.sql
+++ b/kylin-it/src/test/resources/query/sql/query85.sql
@@ -24,3 +24,4 @@ select sum(price) as GMV, count(*) as TRANS_CNT  FROM test_kylin_fact
  AND test_kylin_fact.lstg_site_id = test_category_groupings.site_id 
 where test_kylin_fact.cal_dt < DATE '2012-05-01' or test_kylin_fact.cal_dt > DATE '2013-05-01'
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query86.sql b/kylin-it/src/test/resources/query/sql/query86.sql
index f6feaaf..a5328f8 100644
--- a/kylin-it/src/test/resources/query/sql/query86.sql
+++ b/kylin-it/src/test/resources/query/sql/query86.sql
@@ -22,3 +22,4 @@ select test_kylin_fact.cal_dt, count(*) as mmm from test_kylin_fact inner JOIN e
  ON test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id AND test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id where lstg_format_name = 'Others'  group by test_kylin_fact.cal_dt order by test_kylin_fact.cal_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query87.sql b/kylin-it/src/test/resources/query/sql/query87.sql
index 8e29323..0765f8a 100644
--- a/kylin-it/src/test/resources/query/sql/query87.sql
+++ b/kylin-it/src/test/resources/query/sql/query87.sql
@@ -20,3 +20,4 @@
 select test_kylin_fact.lstg_format_name, sum(price) as GMV, count(*) as TRANS_CNT from test_kylin_fact 
 where test_kylin_fact.lstg_format_name = 'GGGG'
  group by test_kylin_fact.lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query88.sql b/kylin-it/src/test/resources/query/sql/query88.sql
index 7415d3e..2209d48 100644
--- a/kylin-it/src/test/resources/query/sql/query88.sql
+++ b/kylin-it/src/test/resources/query/sql/query88.sql
@@ -20,3 +20,4 @@
 select test_kylin_fact.lstg_format_name, sum(price) as GMV, count(*) as TRANS_CNT from test_kylin_fact 
 where test_kylin_fact.lstg_format_name > 'GGGG'
  group by test_kylin_fact.lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query89.sql b/kylin-it/src/test/resources/query/sql/query89.sql
index 38e8a75..081cd9a 100644
--- a/kylin-it/src/test/resources/query/sql/query89.sql
+++ b/kylin-it/src/test/resources/query/sql/query89.sql
@@ -20,3 +20,4 @@
 select test_kylin_fact.lstg_format_name, sum(price) as GMV, count(*) as TRANS_CNT from test_kylin_fact 
 where test_kylin_fact.lstg_format_name > 'ZZZZ'
  group by test_kylin_fact.lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query90.sql b/kylin-it/src/test/resources/query/sql/query90.sql
index 97d2e25..04e0425 100644
--- a/kylin-it/src/test/resources/query/sql/query90.sql
+++ b/kylin-it/src/test/resources/query/sql/query90.sql
@@ -22,3 +22,4 @@
   select test_kylin_fact.lstg_format_name, sum(price) as GMV, count(price) as GMV_CNT
  from test_kylin_fact where test_kylin_fact.lstg_format_name > 'AB'
  group by test_kylin_fact.lstg_format_name having count(price) > 2
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query91.sql b/kylin-it/src/test/resources/query/sql/query91.sql
index 044a9c1..afe46af 100644
--- a/kylin-it/src/test/resources/query/sql/query91.sql
+++ b/kylin-it/src/test/resources/query/sql/query91.sql
@@ -22,3 +22,4 @@
   select test_kylin_fact.lstg_format_name, sum(price) as GMV, count(price) as GMV_CNT
  from test_kylin_fact where test_kylin_fact.lstg_format_name <= 'ABZ'
  group by test_kylin_fact.lstg_format_name having count(price) > 2
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query92.sql b/kylin-it/src/test/resources/query/sql/query92.sql
index ebc07fe..1d28fa7 100644
--- a/kylin-it/src/test/resources/query/sql/query92.sql
+++ b/kylin-it/src/test/resources/query/sql/query92.sql
@@ -28,3 +28,4 @@ select meta_categ_name, count(1) as cnt, sum(price) as GMV
 
  where meta_categ_name not in ('', 'a')
  group by meta_categ_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query93.sql b/kylin-it/src/test/resources/query/sql/query93.sql
index 085e0e6..5e802a4 100644
--- a/kylin-it/src/test/resources/query/sql/query93.sql
+++ b/kylin-it/src/test/resources/query/sql/query93.sql
@@ -28,3 +28,4 @@ select meta_categ_name, count(1) as cnt, sum(price) as GMV
 
  where meta_categ_name is not null
  group by meta_categ_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query94.sql b/kylin-it/src/test/resources/query/sql/query94.sql
index b39d163..69abd4c 100644
--- a/kylin-it/src/test/resources/query/sql/query94.sql
+++ b/kylin-it/src/test/resources/query/sql/query94.sql
@@ -28,3 +28,4 @@ select meta_categ_name, count(1) as cnt, sum(price) as GMV
 
  where meta_categ_name not in ('Unknown')
  group by meta_categ_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query95.sql b/kylin-it/src/test/resources/query/sql/query95.sql
index fd94dcc..1d97c45 100644
--- a/kylin-it/src/test/resources/query/sql/query95.sql
+++ b/kylin-it/src/test/resources/query/sql/query95.sql
@@ -28,3 +28,4 @@ select meta_categ_name, count(1) as cnt, sum(price) as GMV
 
  where meta_categ_name not in ('Unknown', 'ToyHobbies', '', 'a', 'BookMagazines')
  group by meta_categ_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query96.sql b/kylin-it/src/test/resources/query/sql/query96.sql
index eae99bc..923df09 100644
--- a/kylin-it/src/test/resources/query/sql/query96.sql
+++ b/kylin-it/src/test/resources/query/sql/query96.sql
@@ -19,4 +19,4 @@
 select upper(lstg_format_name) as lstg_format_name, count(*) as cnt from test_kylin_fact
 where lower(lstg_format_name)='abin' and substring(lstg_format_name,1,3) in ('ABI') and upper(lstg_format_name) > 'AAAA' and
 lower(lstg_format_name) like '%b%' and char_length(lstg_format_name) < 10 and char_length(lstg_format_name) > 3 and 'abc'||lstg_format_name||'a'||'b'||'c'='abcABINabc'
-group by lstg_format_name
\ No newline at end of file
+group by lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query97.sql b/kylin-it/src/test/resources/query/sql/query97.sql
index c9c0c6f..b26489c 100644
--- a/kylin-it/src/test/resources/query/sql/query97.sql
+++ b/kylin-it/src/test/resources/query/sql/query97.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.lstg_format_name='XXXUnknown' 
  group by test_cal_dt.cal_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query98.sql b/kylin-it/src/test/resources/query/sql/query98.sql
index 81736d9..f38aaf2 100644
--- a/kylin-it/src/test/resources/query/sql/query98.sql
+++ b/kylin-it/src/test/resources/query/sql/query98.sql
@@ -19,3 +19,4 @@
 select cal_dt,leaf_categ_id as x, sum(price) as GMV 
  from test_kylin_fact 
  group by leaf_categ_id, cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":507904}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql/query99.sql b/kylin-it/src/test/resources/query/sql/query99.sql
index 80a537d..2d840c3 100644
--- a/kylin-it/src/test/resources/query/sql/query99.sql
+++ b/kylin-it/src/test/resources/query/sql/query99.sql
@@ -31,3 +31,4 @@ SELECT
  ,test_category_groupings.meta_categ_name 
  ,test_kylin_fact.lstg_format_name 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_cache/query01.sql b/kylin-it/src/test/resources/query/sql_cache/query01.sql
index e6b601b..6a45735 100644
--- a/kylin-it/src/test/resources/query/sql_cache/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_cache/query01.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.cal_dt < DATE '2012-09-10' AND test_kylin_fact.cal_dt > DATE '2012-01-01'
  group by test_kylin_fact.lstg_format_name, test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_cache/query02.sql b/kylin-it/src/test/resources/query/sql_cache/query02.sql
index 1cee410..a0e6346 100644
--- a/kylin-it/src/test/resources/query/sql_cache/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_cache/query02.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.cal_dt < DATE '2012-10-10'  AND test_kylin_fact.cal_dt > DATE '2012-01-01'
  group by test_kylin_fact.lstg_format_name, test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_cache/query03.sql b/kylin-it/src/test/resources/query/sql_cache/query03.sql
index d311df7..8bb5135 100644
--- a/kylin-it/src/test/resources/query/sql_cache/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_cache/query03.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.cal_dt < DATE '2013-02-10'  AND test_kylin_fact.cal_dt > DATE '2012-01-01'
  group by test_kylin_fact.lstg_format_name, test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_cache/query04.sql b/kylin-it/src/test/resources/query/sql_cache/query04.sql
index 4db7a36..d4bcc63 100644
--- a/kylin-it/src/test/resources/query/sql_cache/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_cache/query04.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.cal_dt < DATE '2013-10-10'  AND test_kylin_fact.cal_dt > DATE '2012-01-01'
  group by test_kylin_fact.lstg_format_name, test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_cache/query05.sql b/kylin-it/src/test/resources/query/sql_cache/query05.sql
index 943c93a..4ba9885 100644
--- a/kylin-it/src/test/resources/query/sql_cache/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_cache/query05.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.cal_dt < DATE '2014-10-10'  AND test_kylin_fact.cal_dt > DATE '2012-01-01'
  group by test_kylin_fact.lstg_format_name, test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_cache/query06.sql b/kylin-it/src/test/resources/query/sql_cache/query06.sql
index 5d8b974..b92e1aa 100644
--- a/kylin-it/src/test/resources/query/sql_cache/query06.sql
+++ b/kylin-it/src/test/resources/query/sql_cache/query06.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.cal_dt < DATE '2013-10-10' AND test_kylin_fact.cal_dt > DATE '2013-09-10'
  group by test_kylin_fact.lstg_format_name, test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_cache/query07.sql b/kylin-it/src/test/resources/query/sql_cache/query07.sql
index 1b1543c..28fdb09 100644
--- a/kylin-it/src/test/resources/query/sql_cache/query07.sql
+++ b/kylin-it/src/test/resources/query/sql_cache/query07.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.cal_dt < DATE '2018-10-10' AND test_kylin_fact.cal_dt > DATE '2009-09-10'
  group by test_kylin_fact.lstg_format_name, test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_cache/query08.sql b/kylin-it/src/test/resources/query/sql_cache/query08.sql
index e6b601b..6a45735 100644
--- a/kylin-it/src/test/resources/query/sql_cache/query08.sql
+++ b/kylin-it/src/test/resources/query/sql_cache/query08.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.cal_dt < DATE '2012-09-10' AND test_kylin_fact.cal_dt > DATE '2012-01-01'
  group by test_kylin_fact.lstg_format_name, test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_cache/query09.sql b/kylin-it/src/test/resources/query/sql_cache/query09.sql
index 1b1543c..28fdb09 100644
--- a/kylin-it/src/test/resources/query/sql_cache/query09.sql
+++ b/kylin-it/src/test/resources/query/sql_cache/query09.sql
@@ -27,3 +27,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_kylin_fact.cal_dt < DATE '2018-10-10' AND test_kylin_fact.cal_dt > DATE '2009-09-10'
  group by test_kylin_fact.lstg_format_name, test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_casewhen/query00.sql b/kylin-it/src/test/resources/query/sql_casewhen/query00.sql
index 2443869..62964fd 100644
--- a/kylin-it/src/test/resources/query/sql_casewhen/query00.sql
+++ b/kylin-it/src/test/resources/query/sql_casewhen/query00.sql
@@ -25,3 +25,4 @@ WHEN 'FOO' THEN 'NO' ELSE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" END)
 
 > 'A')
 GROUP BY "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_casewhen/query01.sql b/kylin-it/src/test/resources/query/sql_casewhen/query01.sql
index ce6e81a..fb0b111 100644
--- a/kylin-it/src/test/resources/query/sql_casewhen/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_casewhen/query01.sql
@@ -24,3 +24,4 @@ WHERE  ( NOT ( ( CASE
                    ELSE NULL 
                  END ) <> 0 ) ) 
 GROUP  BY lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_casewhen/query02.sql b/kylin-it/src/test/resources/query/sql_casewhen/query02.sql
index 697f423..1297332 100644
--- a/kylin-it/src/test/resources/query/sql_casewhen/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_casewhen/query02.sql
@@ -20,3 +20,4 @@ SELECT "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME"
 FROM   TEST_KYLIN_FACT 
 WHERE  ((CASE WHEN ("TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" = 'Auction') THEN 'Auction1' ELSE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" END) = 'Auction1')
 GROUP BY "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_casewhen/query03.sql b/kylin-it/src/test/resources/query/sql_casewhen/query03.sql
index 85c662a..1e90e1f 100644
--- a/kylin-it/src/test/resources/query/sql_casewhen/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_casewhen/query03.sql
@@ -23,3 +23,4 @@ WHERE  (CASE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME"
 	WHEN 'FP-GTC' THEN '222' 
 	ELSE '999' END) = '111'
 GROUP BY "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_casewhen/query04.sql b/kylin-it/src/test/resources/query/sql_casewhen/query04.sql
index 6ea8d51..fa90392 100644
--- a/kylin-it/src/test/resources/query/sql_casewhen/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_casewhen/query04.sql
@@ -33,3 +33,4 @@ group by "TEST_KYLIN_FACT"."ORDER_ID",
            else 'N'
        end
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_casewhen/query55.sql b/kylin-it/src/test/resources/query/sql_casewhen/query55.sql
index d29b60d..d008154 100644
--- a/kylin-it/src/test/resources/query/sql_casewhen/query55.sql
+++ b/kylin-it/src/test/resources/query/sql_casewhen/query55.sql
@@ -20,3 +20,4 @@ SELECT (CASE WHEN ("TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" IN ('Auction', 'FP-GTC')
   SUM("TEST_KYLIN_FACT"."PRICE") AS "sum_PRICE_ok"
 FROM "TEST_KYLIN_FACT" "TEST_KYLIN_FACT"
 GROUP BY (CASE WHEN ("TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" IN ('Auction', 'FP-GTC')) THEN 'Auction' ELSE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" END)
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_casewhen/query56.sql b/kylin-it/src/test/resources/query/sql_casewhen/query56.sql
index 7006fbf..2d59612 100644
--- a/kylin-it/src/test/resources/query/sql_casewhen/query56.sql
+++ b/kylin-it/src/test/resources/query/sql_casewhen/query56.sql
@@ -20,3 +20,4 @@
   SUM("TEST_KYLIN_FACT"."PRICE") AS "sum_PRICE_ok"
 FROM "TEST_KYLIN_FACT" "TEST_KYLIN_FACT"
 GROUP BY (CASE WHEN ("TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" =  'Auction') THEN 'Auction2' ELSE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" END)
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_casewhen/query57.sql b/kylin-it/src/test/resources/query/sql_casewhen/query57.sql
index 76ae649..41059c7 100644
--- a/kylin-it/src/test/resources/query/sql_casewhen/query57.sql
+++ b/kylin-it/src/test/resources/query/sql_casewhen/query57.sql
@@ -20,4 +20,4 @@ SELECT (CASE WHEN ("TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" IN ('Auction', 'FP-GTC')
   SUM("TEST_KYLIN_FACT"."PRICE") AS "sum_PRICE_ok"
 FROM "TEST_KYLIN_FACT" "TEST_KYLIN_FACT"
 GROUP BY (CASE WHEN ("TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" IN ('Auction', 'FP-GTC')) THEN 'Auction' ELSE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" END)
-LIMIT 4
\ No newline at end of file
+LIMIT 4;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_datetime/query00.sql b/kylin-it/src/test/resources/query/sql_datetime/query00.sql
index d0300e7..e9cf41e 100644
--- a/kylin-it/src/test/resources/query/sql_datetime/query00.sql
+++ b/kylin-it/src/test/resources/query/sql_datetime/query00.sql
@@ -11,4 +11,4 @@ INNER JOIN TEST_CATEGORY_GROUPINGS as TEST_CATEGORY_GROUPINGS
 ON TEST_KYLIN_FACT.LEAF_CATEG_ID = TEST_CATEGORY_GROUPINGS.LEAF_CATEG_ID AND TEST_KYLIN_FACT.LSTG_SITE_ID = TEST_CATEGORY_GROUPINGS.SITE_ID
 
 group by TEST_ORDER.ORDER_ID
-order by TEST_ORDER.ORDER_ID
\ No newline at end of file
+order by TEST_ORDER.ORDER_ID;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":788464}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query01.sql b/kylin-it/src/test/resources/query/sql_derived/query01.sql
index c4b0aae..bc8939e 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query01.sql
@@ -45,3 +45,4 @@ SELECT
  ,test_sites.site_name 
  ,test_sites.site_id 
  ,test_sites.cre_user 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query02.sql b/kylin-it/src/test/resources/query/sql_derived/query02.sql
index 027cd9c..511c8ce 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query02.sql
@@ -45,3 +45,4 @@ SELECT
  ,test_sites.site_name 
  ,test_sites.site_id 
  ,test_sites.cre_user 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query03.sql b/kylin-it/src/test/resources/query/sql_derived/query03.sql
index 35736b9..2d74e52 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query03.sql
@@ -19,3 +19,4 @@
 SELECT distinct LSTG_FORMAT_NAME from test_kylin_fact 
  
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query04.sql b/kylin-it/src/test/resources/query/sql_derived/query04.sql
index dab5d0f..32fb419 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query04.sql
@@ -18,3 +18,4 @@
 
 SELECT site_id, site_name, cre_user from edw.test_sites 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query05.sql b/kylin-it/src/test/resources/query/sql_derived/query05.sql
index 61a9b2c..8ebe00a 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query05.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY 
  test_sites.site_name, test_kylin_fact.lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query06.sql b/kylin-it/src/test/resources/query/sql_derived/query06.sql
index 0ea32b2..cfeee14 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query06.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query06.sql
@@ -18,3 +18,4 @@
 
 SELECT distinct cal_dt from test_kylin_fact 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query07.sql b/kylin-it/src/test/resources/query/sql_derived/query07.sql
index a27fbd1..1e952fe 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query07.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query07.sql
@@ -20,3 +20,4 @@ select cal_dt, lstg_format_name, sum(price) as GMV
  from test_kylin_fact 
  where cal_dt=date '2013-05-06' 
  group by cal_dt, lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query09.sql b/kylin-it/src/test/resources/query/sql_derived/query09.sql
index c0aacef..8ba22a6 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query09.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query09.sql
@@ -17,3 +17,4 @@
 --
 
 select distinct leaf_categ_id, site_id from test_category_groupings 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query10.sql b/kylin-it/src/test/resources/query/sql_derived/query10.sql
index dd29659..35fcf77 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query10.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query10.sql
@@ -42,3 +42,4 @@ SELECT
  ,test_category_groupings.leaf_categ_id 
  ,test_kylin_fact.lstg_site_id 
  ,test_category_groupings.site_id 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query11.sql b/kylin-it/src/test/resources/query/sql_derived/query11.sql
index 41157c5..f271c34 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query11.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query11.sql
@@ -24,3 +24,4 @@ select test_cal_dt.week_beg_dt, test_kylin_fact.lstg_format_name, test_category_
  ON test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id AND test_kylin_fact.lstg_site_id = test_category_groupings.site_id 
  where test_cal_dt.week_beg_dt between DATE '2013-05-01' and DATE '2013-10-01' 
  group by test_cal_dt.week_beg_dt, test_kylin_fact.lstg_format_name, test_category_groupings.meta_categ_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query12.sql b/kylin-it/src/test/resources/query/sql_derived/query12.sql
index f1f331c..9f2ea2b 100755
--- a/kylin-it/src/test/resources/query/sql_derived/query12.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query12.sql
@@ -21,4 +21,4 @@ from TEST_KYLIN_FACT  as TEST_KYLIN_FACT
 inner join TEST_CATEGORY_GROUPINGS as TEST_CATEGORY_GROUPINGS
 ON TEST_KYLIN_FACT.LEAF_CATEG_ID = TEST_CATEGORY_GROUPINGS.LEAF_CATEG_ID AND TEST_KYLIN_FACT.LSTG_SITE_ID = TEST_CATEGORY_GROUPINGS.SITE_ID
 where UPD_USER not in ('USER_Y')
-group by UPD_USER
\ No newline at end of file
+group by UPD_USER;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_derived/query13.sql b/kylin-it/src/test/resources/query/sql_derived/query13.sql
index 754495f..eae6c10 100644
--- a/kylin-it/src/test/resources/query/sql_derived/query13.sql
+++ b/kylin-it/src/test/resources/query/sql_derived/query13.sql
@@ -23,4 +23,4 @@ select test_cal_dt.week_beg_dt, test_kylin_fact.lstg_format_name, test_category_
  inner JOIN test_category_groupings
  ON test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id AND test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  where test_cal_dt.week_beg_dt is not null
- group by test_cal_dt.week_beg_dt, test_kylin_fact.lstg_format_name, test_category_groupings.meta_categ_name
\ No newline at end of file
+ group by test_cal_dt.week_beg_dt, test_kylin_fact.lstg_format_name, test_category_groupings.meta_categ_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct/query00.sql b/kylin-it/src/test/resources/query/sql_distinct/query00.sql
index 03a2ada..32894e8 100644
--- a/kylin-it/src/test/resources/query/sql_distinct/query00.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct/query00.sql
@@ -22,3 +22,4 @@ select lstg_format_name, cal_dt,
  count(distinct seller_id) as DIST_SELLER 
  from test_kylin_fact 
  group by lstg_format_name, cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct/query01.sql b/kylin-it/src/test/resources/query/sql_distinct/query01.sql
index 9f92497..d5a9627 100644
--- a/kylin-it/src/test/resources/query/sql_distinct/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct/query01.sql
@@ -23,3 +23,4 @@ select lstg_format_name,
  from test_kylin_fact 
  where lstg_format_name='FP-GTC' 
  group by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct/query02.sql b/kylin-it/src/test/resources/query/sql_distinct/query02.sql
index a903bf3..faf98e5 100644
--- a/kylin-it/src/test/resources/query/sql_distinct/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct/query02.sql
@@ -24,3 +24,4 @@ select lstg_format_name,
  where lstg_format_name='FP-GTC' 
  group by lstg_format_name 
  having count(distinct seller_id) > 50 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct/query03.sql b/kylin-it/src/test/resources/query/sql_distinct/query03.sql
index 61ab376..9989d8a 100644
--- a/kylin-it/src/test/resources/query/sql_distinct/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct/query03.sql
@@ -24,3 +24,4 @@ select test_cal_dt.week_beg_dt,sum(test_kylin_fact.price) as GMV
  where test_kylin_fact.lstg_format_name='FP-GTC' 
  and test_cal_dt.week_beg_dt between DATE '2013-05-01' and DATE '2013-08-01' 
  group by test_cal_dt.week_beg_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct/query04.sql b/kylin-it/src/test/resources/query/sql_distinct/query04.sql
index cb118fa..cf85871 100644
--- a/kylin-it/src/test/resources/query/sql_distinct/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct/query04.sql
@@ -25,3 +25,4 @@ select test_cal_dt.week_beg_dt,sum(test_kylin_fact.price) as GMV
  and test_cal_dt.week_beg_dt between DATE '2013-05-01' and DATE '2013-08-01' 
  group by test_cal_dt.week_beg_dt 
  having count(distinct seller_id) > 2 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct/query05.sql b/kylin-it/src/test/resources/query/sql_distinct/query05.sql
index cee8ef4..abf50af 100644
--- a/kylin-it/src/test/resources/query/sql_distinct/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct/query05.sql
@@ -23,3 +23,4 @@ select lstg_format_name,
  from test_kylin_fact 
  group by lstg_format_name 
  order by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct/query06.sql b/kylin-it/src/test/resources/query/sql_distinct/query06.sql
index 4a46048..44ff18a 100644
--- a/kylin-it/src/test/resources/query/sql_distinct/query06.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct/query06.sql
@@ -24,3 +24,4 @@ select lstg_format_name,
  where lstg_format_name='FP-GTC' 
  group by lstg_format_name 
  order by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct/query07.sql b/kylin-it/src/test/resources/query/sql_distinct/query07.sql
index b76cdc8..75af0c2 100644
--- a/kylin-it/src/test/resources/query/sql_distinct/query07.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct/query07.sql
@@ -22,3 +22,4 @@ select lstg_format_name,
  count(distinct seller_id) as DIST_SELLER 
  from test_kylin_fact 
  group by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct_dim/query100.sql b/kylin-it/src/test/resources/query/sql_distinct_dim/query100.sql
index 4095c80..f504817 100644
--- a/kylin-it/src/test/resources/query/sql_distinct_dim/query100.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct_dim/query100.sql
@@ -28,4 +28,4 @@ SELECT
  ON test_kylin_fact.cal_dt = test_cal_dt.cal_dt
  inner JOIN test_category_groupings
  ON test_kylin_fact.lstg_site_id = test_category_groupings.site_id  AND test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id
- group by  test_kylin_fact.seller_id
\ No newline at end of file
+ group by  test_kylin_fact.seller_id;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct_dim/query101.sql b/kylin-it/src/test/resources/query/sql_distinct_dim/query101.sql
index a5350c4..eb95956 100644
--- a/kylin-it/src/test/resources/query/sql_distinct_dim/query101.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct_dim/query101.sql
@@ -18,4 +18,4 @@
 
 select seller_id, lstg_site_id, count(DISTINCT leaf_categ_id) as CategCount
 from test_kylin_fact
-group by seller_id, lstg_site_id
\ No newline at end of file
+group by seller_id, lstg_site_id;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct_precisely/query00.sql b/kylin-it/src/test/resources/query/sql_distinct_precisely/query00.sql
index 762ea38..e7e247c 100644
--- a/kylin-it/src/test/resources/query/sql_distinct_precisely/query00.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct_precisely/query00.sql
@@ -22,3 +22,4 @@ select lstg_format_name, cal_dt,
  count(distinct TEST_COUNT_DISTINCT_BITMAP) as user_count
  from test_kylin_fact
  group by lstg_format_name, cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct_precisely/query01.sql b/kylin-it/src/test/resources/query/sql_distinct_precisely/query01.sql
index b05f022..c645137 100644
--- a/kylin-it/src/test/resources/query/sql_distinct_precisely/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct_precisely/query01.sql
@@ -23,3 +23,4 @@ select lstg_format_name,
  from test_kylin_fact
  where lstg_format_name='FP-GTC'
  group by lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct_precisely/query02.sql b/kylin-it/src/test/resources/query/sql_distinct_precisely/query02.sql
index 44abae2..b526478 100644
--- a/kylin-it/src/test/resources/query/sql_distinct_precisely/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct_precisely/query02.sql
@@ -24,3 +24,4 @@ select lstg_format_name,
  where lstg_format_name='FP-GTC'
  group by lstg_format_name
  having user_count > 50
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct_precisely/query03.sql b/kylin-it/src/test/resources/query/sql_distinct_precisely/query03.sql
index 7434769..4842dc3 100644
--- a/kylin-it/src/test/resources/query/sql_distinct_precisely/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct_precisely/query03.sql
@@ -33,3 +33,4 @@ select test_cal_dt.cal_dt,sum(test_kylin_fact.price) as GMV
  where test_kylin_fact.lstg_format_name='FP-GTC'
  and test_cal_dt.cal_dt between DATE '2013-05-01' and DATE '2013-08-01'
  group by test_cal_dt.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_distinct_precisely/query04.sql b/kylin-it/src/test/resources/query/sql_distinct_precisely/query04.sql
index 2bd4d26..0acca59 100644
--- a/kylin-it/src/test/resources/query/sql_distinct_precisely/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_distinct_precisely/query04.sql
@@ -34,3 +34,4 @@ select test_cal_dt.cal_dt,sum(test_kylin_fact.price) as GMV
  and test_cal_dt.cal_dt between DATE '2013-05-01' and DATE '2013-08-01'
  group by test_cal_dt.cal_dt
  having user_count > 2
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_grouping/query00.sql b/kylin-it/src/test/resources/query/sql_grouping/query00.sql
index 716960d..d664ddd 100644
--- a/kylin-it/src/test/resources/query/sql_grouping/query00.sql
+++ b/kylin-it/src/test/resources/query/sql_grouping/query00.sql
@@ -22,4 +22,4 @@ select
 sum(price) as GMV,
 count(*) as TRANS_CNT from test_kylin_fact
 where cal_dt between '2012-01-01' and '2012-02-01'
-group by cube(lstg_format_name, cal_dt, slr_segment_cd)
\ No newline at end of file
+group by cube(lstg_format_name, cal_dt, slr_segment_cd);{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_grouping/query01.sql b/kylin-it/src/test/resources/query/sql_grouping/query01.sql
index aa824fe..87b164e 100644
--- a/kylin-it/src/test/resources/query/sql_grouping/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_grouping/query01.sql
@@ -22,4 +22,4 @@ select
 sum(price) as GMV,
 count(*) as TRANS_CNT from test_kylin_fact
 where cal_dt between '2012-01-01' and '2012-02-01'
-group by rollup(lstg_format_name, cal_dt, slr_segment_cd)
\ No newline at end of file
+group by rollup(lstg_format_name, cal_dt, slr_segment_cd);{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_grouping/query02.sql b/kylin-it/src/test/resources/query/sql_grouping/query02.sql
index 33dec3a..a5242ab 100644
--- a/kylin-it/src/test/resources/query/sql_grouping/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_grouping/query02.sql
@@ -23,3 +23,4 @@ sum(price) as GMV,
 count(*) as TRANS_CNT from test_kylin_fact
 where cal_dt between '2012-01-01' and '2012-02-01'
 group by grouping sets((lstg_format_name, cal_dt, slr_segment_cd), (cal_dt, slr_segment_cd), (lstg_format_name, slr_segment_cd))
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_h2_uncapable/query03.sql b/kylin-it/src/test/resources/query/sql_h2_uncapable/query03.sql
index 5455a05..1a8298b 100644
--- a/kylin-it/src/test/resources/query/sql_h2_uncapable/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_h2_uncapable/query03.sql
@@ -1,4 +1,4 @@
 select "TEST_KYLIN_FACT"."CAL_DT" as "CAL_DT"
 from "DEFAULT"."TEST_KYLIN_FACT" "TEST_KYLIN_FACT"
 where ("TEST_KYLIN_FACT"."CAL_DT" ) >= DATE'2013-01-07' + interval '3' day
-group by "TEST_KYLIN_FACT"."CAL_DT" order by "TEST_KYLIN_FACT"."CAL_DT"
\ No newline at end of file
+group by "TEST_KYLIN_FACT"."CAL_DT" order by "TEST_KYLIN_FACT"."CAL_DT";{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_h2_uncapable/query04.sql b/kylin-it/src/test/resources/query/sql_h2_uncapable/query04.sql
index 5ece9c9..6afe503 100644
--- a/kylin-it/src/test/resources/query/sql_h2_uncapable/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_h2_uncapable/query04.sql
@@ -2,4 +2,4 @@ select "TEST_KYLIN_FACT"."CAL_DT" as "CAL_DT"
 from "DEFAULT"."TEST_KYLIN_FACT" "TEST_KYLIN_FACT"
 where ("TEST_KYLIN_FACT"."CAL_DT" + interval '3' day ) >= DATE'2013-01-07'
 group by "TEST_KYLIN_FACT"."CAL_DT"
-order by "TEST_KYLIN_FACT"."CAL_DT"
\ No newline at end of file
+order by "TEST_KYLIN_FACT"."CAL_DT";{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_h2_uncapable/query05.sql b/kylin-it/src/test/resources/query/sql_h2_uncapable/query05.sql
index 60f02e7..4f6b315 100644
--- a/kylin-it/src/test/resources/query/sql_h2_uncapable/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_h2_uncapable/query05.sql
@@ -22,3 +22,4 @@ select cal_dt,
  count(distinct seller_id, lstg_format_name) as DIST_SELLER_FORMAT
  from test_kylin_fact 
  group by cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_join/query_00.sql b/kylin-it/src/test/resources/query/sql_join/query_00.sql
index 024e45d..e5aacc3 100644
--- a/kylin-it/src/test/resources/query/sql_join/query_00.sql
+++ b/kylin-it/src/test/resources/query/sql_join/query_00.sql
@@ -18,4 +18,4 @@ ON TEST_KYLIN_FACT.SLR_SEGMENT_CD = TEST_SELLER_TYPE_DIM.SELLER_TYPE_CD
 INNER JOIN TEST_COUNTRY as BUYER_COUNTRY
 ON BUYER_ACCOUNT.ACCOUNT_COUNTRY = BUYER_COUNTRY.COUNTRY
 INNER JOIN TEST_COUNTRY as SELLER_COUNTRY
-ON SELLER_ACCOUNT.ACCOUNT_COUNTRY = SELLER_COUNTRY.COUNTRY
\ No newline at end of file
+ON SELLER_ACCOUNT.ACCOUNT_COUNTRY = SELLER_COUNTRY.COUNTRY;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query01.sql b/kylin-it/src/test/resources/query/sql_like/query01.sql
index e3a05ca..f3750de 100644
--- a/kylin-it/src/test/resources/query/sql_like/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query01.sql
@@ -29,3 +29,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
 where META_CATEG_NAME like '%ab%'
 group by META_CATEG_NAME
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query02.sql b/kylin-it/src/test/resources/query/sql_like/query02.sql
index ef0b4a0..7126800 100644
--- a/kylin-it/src/test/resources/query/sql_like/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query02.sql
@@ -19,4 +19,4 @@
 select upper(lstg_format_name) as lstg_format_name, count(*) as cnt from test_kylin_fact
 where lower(lstg_format_name)='abin_a' and substring(lstg_format_name,1,3) in ('ABI') and upper(lstg_format_name) > 'AAAA' and
 lower(lstg_format_name) like '%b%' and char_length(lstg_format_name) < 10 and char_length(lstg_format_name) > 3 and lstg_format_name||'a'='ABIN_Aa'
-group by lstg_format_name
\ No newline at end of file
+group by lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query03.sql b/kylin-it/src/test/resources/query/sql_like/query03.sql
index ae095fc..80735b4 100644
--- a/kylin-it/src/test/resources/query/sql_like/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query03.sql
@@ -30,4 +30,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
  
 where lstg_format_name like '%BIN%' and lstg_format_name > 'A'
-group by lstg_format_name
\ No newline at end of file
+group by lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query04.sql b/kylin-it/src/test/resources/query/sql_like/query04.sql
index faf5ca3..6e41f9b 100644
--- a/kylin-it/src/test/resources/query/sql_like/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query04.sql
@@ -19,4 +19,4 @@
 select upper(lstg_format_name) as lstg_format_name, count(*) as cnt from test_kylin_fact
 where lower(lstg_format_name)='auction' and substring(lstg_format_name,1,3) in ('Auc') and upper(lstg_format_name) > 'AAAA' and
 upper(lstg_format_name) like '%UC%' and char_length(lstg_format_name) < 10 and char_length(lstg_format_name) > 3 and lstg_format_name||'a'='Auctiona'
-group by lstg_format_name
\ No newline at end of file
+group by lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query05.sql b/kylin-it/src/test/resources/query/sql_like/query05.sql
index 6ac9758..ce02134 100644
--- a/kylin-it/src/test/resources/query/sql_like/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query05.sql
@@ -31,3 +31,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
 where lower(meta_categ_name)='baby' and substring(meta_categ_name,1,3) in ('Bab') and upper(meta_categ_name) > 'AAAA' and
 lower(meta_categ_name) like '%b%' and char_length(meta_categ_name) < 10 and char_length(meta_categ_name) > 3 and meta_categ_name||'a'='Babya'
 group by meta_categ_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query06.sql b/kylin-it/src/test/resources/query/sql_like/query06.sql
index 6417584..d0a12ff 100644
--- a/kylin-it/src/test/resources/query/sql_like/query06.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query06.sql
@@ -31,3 +31,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
 where META_CATEG_NAME like '%ab%' and META_CATEG_NAME > 'A'
 group by META_CATEG_NAME
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query10.sql b/kylin-it/src/test/resources/query/sql_like/query10.sql
index 21632f4..480324a 100644
--- a/kylin-it/src/test/resources/query/sql_like/query10.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query10.sql
@@ -11,3 +11,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
  
 where USER_DEFINED_FIELD3 like '%Video Game%'
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query15.sql b/kylin-it/src/test/resources/query/sql_like/query15.sql
index 85418c7..d48ab58 100644
--- a/kylin-it/src/test/resources/query/sql_like/query15.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query15.sql
@@ -11,3 +11,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
  
 where lower(USER_DEFINED_FIELD3) like '%Video Game%'
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query16.sql b/kylin-it/src/test/resources/query/sql_like/query16.sql
index 2a484ef..1e3e2d6 100644
--- a/kylin-it/src/test/resources/query/sql_like/query16.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query16.sql
@@ -11,3 +11,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
  
 where lower(USER_DEFINED_FIELD3) like '%video game%'
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query17.sql b/kylin-it/src/test/resources/query/sql_like/query17.sql
index c6dd1ea..b850299 100644
--- a/kylin-it/src/test/resources/query/sql_like/query17.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query17.sql
@@ -11,3 +11,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
  
 where upper(USER_DEFINED_FIELD3) like '%VIDEO GAME%'
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query18.sql b/kylin-it/src/test/resources/query/sql_like/query18.sql
index 8ef6ad4..e0a383a 100644
--- a/kylin-it/src/test/resources/query/sql_like/query18.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query18.sql
@@ -11,3 +11,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
  
 where upper(USER_DEFINED_FIELD3) like '%VID%'
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query20.sql b/kylin-it/src/test/resources/query/sql_like/query20.sql
index 6101cb0..c05f2f8 100644
--- a/kylin-it/src/test/resources/query/sql_like/query20.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query20.sql
@@ -28,4 +28,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
  
 where lstg_format_name not like '%BIN%'
-group by lstg_format_name
\ No newline at end of file
+group by lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query21.sql b/kylin-it/src/test/resources/query/sql_like/query21.sql
index 368a15c..6c923de 100644
--- a/kylin-it/src/test/resources/query/sql_like/query21.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query21.sql
@@ -28,4 +28,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
  
 where not(lstg_format_name not like '%BIN%')
-group by lstg_format_name
\ No newline at end of file
+group by lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query22.sql b/kylin-it/src/test/resources/query/sql_like/query22.sql
index a962d3f..1e7947b 100644
--- a/kylin-it/src/test/resources/query/sql_like/query22.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query22.sql
@@ -29,3 +29,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
 where META_CATEG_NAME not like '%ab%'
 group by META_CATEG_NAME
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_like/query23.sql b/kylin-it/src/test/resources/query/sql_like/query23.sql
index b3a78c2..266b87e 100644
--- a/kylin-it/src/test/resources/query/sql_like/query23.sql
+++ b/kylin-it/src/test/resources/query/sql_like/query23.sql
@@ -29,3 +29,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  
 where not(META_CATEG_NAME not like '%ab%')
 group by META_CATEG_NAME
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":65536}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query01.sql b/kylin-it/src/test/resources/query/sql_lookup/query01.sql
index eb08c01..0471ef6 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query01.sql
@@ -22,3 +22,4 @@ select CAL_DT, WEEK_BEG_DT from edw.test_cal_dt
 
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query02.sql b/kylin-it/src/test/resources/query/sql_lookup/query02.sql
index b667519..2413e76 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query02.sql
@@ -17,3 +17,4 @@
 --
 
 select CATEG_LVL3_NAME, CATEG_LVL2_NAME, SITE_ID, META_CATEG_NAME, LEAF_CATEG_ID  from test_category_groupings
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query03.sql b/kylin-it/src/test/resources/query/sql_lookup/query03.sql
index f663627..9517321 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query03.sql
@@ -17,3 +17,4 @@
 --
 
 select SELLER_TYPE_DESC, SELLER_TYPE_CD from edw.test_seller_type_dim
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query04.sql b/kylin-it/src/test/resources/query/sql_lookup/query04.sql
index 69a77d7..0bb38cb 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query04.sql
@@ -17,3 +17,4 @@
 --
 
 select SITE_NAME, SITE_ID from edw.test_sites
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query05.sql b/kylin-it/src/test/resources/query/sql_lookup/query05.sql
index 31fdf61..73ee246 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query05.sql
@@ -17,3 +17,4 @@
 --
 
 select count(distinct META_CATEG_NAME) as CNT ,max(META_CATEG_NAME) as y from test_category_groupings
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query06.sql b/kylin-it/src/test/resources/query/sql_lookup/query06.sql
index e2b8469..f1dd9be 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query06.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query06.sql
@@ -1 +1 @@
-select max(cal_dt) as x from edw.test_cal_dt
\ No newline at end of file
+select max(cal_dt) as x from edw.test_cal_dt;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query07.sql b/kylin-it/src/test/resources/query/sql_lookup/query07.sql
index 6be3439..3aeff8e 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query07.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query07.sql
@@ -1 +1,2 @@
 select site_id,count(*) as y,count(DISTINCT site_name) as x from edw.test_sites group by site_id
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query45.sql b/kylin-it/src/test/resources/query/sql_lookup/query45.sql
index ea964ae..508fca5 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query45.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query45.sql
@@ -22,3 +22,4 @@ select count(*) as CNT from edw.test_cal_dt
 
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query46.sql b/kylin-it/src/test/resources/query/sql_lookup/query46.sql
index 3bfe9d9..61bbc24 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query46.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query46.sql
@@ -17,3 +17,4 @@
 --
 
 select count(*) as CNT  from test_category_groupings
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query47.sql b/kylin-it/src/test/resources/query/sql_lookup/query47.sql
index cbd2c6d..c455974 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query47.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query47.sql
@@ -17,3 +17,4 @@
 --
 
 select count(*) as CNT  from edw.test_seller_type_dim
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query48.sql b/kylin-it/src/test/resources/query/sql_lookup/query48.sql
index 54ddb31..d14b567 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query48.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query48.sql
@@ -17,3 +17,4 @@
 --
 
 select count(*) as CNT from edw.test_sites
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_lookup/query55.sql b/kylin-it/src/test/resources/query/sql_lookup/query55.sql
index 346a7d7..649a242 100644
--- a/kylin-it/src/test/resources/query/sql_lookup/query55.sql
+++ b/kylin-it/src/test/resources/query/sql_lookup/query55.sql
@@ -17,3 +17,4 @@
 --
 
 select count(*) as c from edw.test_cal_dt as test_cal_dt where extract(YEAR from test_cal_dt.cal_dt) = 2012
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_orderby/query01.sql b/kylin-it/src/test/resources/query/sql_orderby/query01.sql
index a1d5065..b78fd22 100644
--- a/kylin-it/src/test/resources/query/sql_orderby/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_orderby/query01.sql
@@ -30,3 +30,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  order by test_cal_dt.week_beg_dt   
 
  -- optiq 0.8 reports varchar instead of date on week_beg_dt and fail test case
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_orderby/query02.sql b/kylin-it/src/test/resources/query/sql_orderby/query02.sql
index cdcef50..4774a42 100644
--- a/kylin-it/src/test/resources/query/sql_orderby/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_orderby/query02.sql
@@ -23,3 +23,4 @@ select lstg_format_name,
  where lstg_format_name='FP-GTC' 
  group by lstg_format_name 
  order by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_orderby/query03.sql b/kylin-it/src/test/resources/query/sql_orderby/query03.sql
index 69854e2..ded9a3a 100644
--- a/kylin-it/src/test/resources/query/sql_orderby/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_orderby/query03.sql
@@ -22,3 +22,4 @@ select lstg_format_name,
  from test_kylin_fact 
  group by lstg_format_name 
  order by sum(price)
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_percentile/query01.sql b/kylin-it/src/test/resources/query/sql_percentile/query01.sql
index 35fcb93..6bf53a6 100644
--- a/kylin-it/src/test/resources/query/sql_percentile/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_percentile/query01.sql
@@ -17,4 +17,4 @@
 --
 
 select seller_id, percentile(price, 0.5) from test_kylin_fact
-group by seller_id
\ No newline at end of file
+group by seller_id;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":1310735}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_percentile/query02.sql b/kylin-it/src/test/resources/query/sql_percentile/query02.sql
index e78b985..00f37b2 100644
--- a/kylin-it/src/test/resources/query/sql_percentile/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_percentile/query02.sql
@@ -17,4 +17,4 @@
 --
 
 select seller_id, percentile_approx(price, 0.5) from test_kylin_fact
-group by seller_id
\ No newline at end of file
+group by seller_id;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":1310735}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query00.sql b/kylin-it/src/test/resources/query/sql_subquery/query00.sql
index ca1fe9b..01109d7 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query00.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query00.sql
@@ -25,3 +25,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  group by test_cal_dt.week_beg_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query01.sql b/kylin-it/src/test/resources/query/sql_subquery/query01.sql
index a2a9bd6..4a64898 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query01.sql
@@ -29,3 +29,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  group by test_cal_dt.week_beg_dt 
  ) "TableauSQL" 
  HAVING COUNT(1)>0 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query02.sql b/kylin-it/src/test/resources/query/sql_subquery/query02.sql
index 342aa32..5625b35 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query02.sql
@@ -33,3 +33,4 @@ FROM
       ON test_kylin_fact.lstg_site_id = test_sites.site_id
 ) t
 group by week_beg_dt 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query03.sql b/kylin-it/src/test/resources/query/sql_subquery/query03.sql
index 07f4f08..bc53ee8 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query03.sql
@@ -34,3 +34,4 @@ inner join
  ON test_kylin_fact.lstg_site_id = test_sites.site_id group by test_kylin_fact.cal_dt order by 2 desc limit 7
 ) cal_2 on fact.cal_dt = cal_2.cal_dt 
 group by fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query04.sql b/kylin-it/src/test/resources/query/sql_subquery/query04.sql
index 837cb0d..537ee7b 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query04.sql
@@ -34,3 +34,4 @@ inner join
  ON test_kylin_fact.lstg_site_id = test_sites.site_id group by test_kylin_fact.cal_dt order by 2 desc limit 7
 ) cal_2 on fact.cal_dt = cal_2.mmm
 group by fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query05.sql b/kylin-it/src/test/resources/query/sql_subquery/query05.sql
index c3bc2bb..9d11b6c 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query05.sql
@@ -35,3 +35,4 @@ SELECT  SUM("TEST_KYLIN_FACT"."PRICE") AS "sum_PRICE_ok"
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
      GROUP BY "TEST_KYLIN_FACT"."CAL_DT"   ORDER BY 2 DESC   LIMIT 10  ) "t0" ON ("TEST_KYLIN_FACT"."CAL_DT" = "t0"."none_CAL_DT_ok") 
     GROUP BY "TEST_KYLIN_FACT"."CAL_DT"
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query06.sql b/kylin-it/src/test/resources/query/sql_subquery/query06.sql
index 7a8b26a..63a5df0 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query06.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query06.sql
@@ -22,3 +22,4 @@ SELECT "TEST_KYLIN_FACT"."CAL_DT", SUM("TEST_KYLIN_FACT"."PRICE") AS "sum_PRICE_
              GROUP BY "TEST_KYLIN_FACT"."CAL_DT"   ORDER BY 2 DESC   LIMIT 7  )
 
     "t0" ON ("TEST_KYLIN_FACT"."CAL_DT" = "t0"."none_CAL_DT_ok") GROUP BY "TEST_KYLIN_FACT"."CAL_DT"
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query07.sql b/kylin-it/src/test/resources/query/sql_subquery/query07.sql
index 0553855..51051a6 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query07.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query07.sql
@@ -22,3 +22,4 @@ inner join (
 select count(1) as cnt, min(cal_dt) as "mmm",  cal_dt as dt from test_kylin_fact group by cal_dt order by 2 desc limit 10
 ) t0 on (fact.cal_dt = t0.dt) 
 group by cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query08.sql b/kylin-it/src/test/resources/query/sql_subquery/query08.sql
index 48da204..60f6327 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query08.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query08.sql
@@ -39,4 +39,4 @@ inner join  (
   ON test_kylin_fact.lstg_site_id = test_sites.site_id
   group by test_cal_dt.week_beg_dt
 ) t2
-on t1.week_beg_dt=t2.week_beg_dt
\ No newline at end of file
+on t1.week_beg_dt=t2.week_beg_dt;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query09.sql b/kylin-it/src/test/resources/query/sql_subquery/query09.sql
index 436ced5..3779e78 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query09.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query09.sql
@@ -40,4 +40,4 @@ inner join  (
   group by test_cal_dt.week_beg_dt
 ) t2
 on t1.week_beg_dt=t2.week_beg_dt
-order by t1.week_beg_dt
\ No newline at end of file
+order by t1.week_beg_dt;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query10.sql b/kylin-it/src/test/resources/query/sql_subquery/query10.sql
index 1edf92d..39e56d1 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query10.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query10.sql
@@ -26,3 +26,4 @@ join
 (select leaf_categ_id, min(price) as min_price from test_kylin_fact group by leaf_categ_id) t3
 on t1.leaf_categ_id = t3.leaf_categ_id
 order by t1.leaf_categ_id
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query11.sql b/kylin-it/src/test/resources/query/sql_subquery/query11.sql
index ce1f978..ed04c44 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query11.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query11.sql
@@ -23,3 +23,4 @@ inner join  (select leaf_categ_id,site_id,meta_categ_name from test_category_gro
 on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and
 test_kylin_fact.lstg_site_id = test_category_groupings.site_id
 group by test_category_groupings.meta_categ_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query12.sql b/kylin-it/src/test/resources/query/sql_subquery/query12.sql
index 6ed45fa..b6e0f17 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query12.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query12.sql
@@ -35,3 +35,4 @@ where
   f.slr_segment_cd = min_seg
 group by
   f.lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query13.sql b/kylin-it/src/test/resources/query/sql_subquery/query13.sql
index d7f6109..90c9501 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query13.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query13.sql
@@ -5,3 +5,4 @@ where
     f.cal_dt not in (
         select cal_dt from EDW.TEST_CAL_DT where week_beg_dt = date'2012-01-01'
     )
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query14.sql b/kylin-it/src/test/resources/query/sql_subquery/query14.sql
index b3b3b7e..3f2e0a6 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query14.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query14.sql
@@ -19,4 +19,4 @@ from
 where
     lstg_format_name ='Auction'
 group by
-    lstg_format_name
\ No newline at end of file
+    lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query15.sql b/kylin-it/src/test/resources/query/sql_subquery/query15.sql
index 330dc27..372c6f5 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query15.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query15.sql
@@ -26,4 +26,4 @@ WHERE
         FROM
             test_kylin_fact
         WHERE
-            lstg_format_name = 'ABIN')
\ No newline at end of file
+            lstg_format_name = 'ABIN');{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query16.sql b/kylin-it/src/test/resources/query/sql_subquery/query16.sql
index 5477e54..bbde260 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query16.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query16.sql
@@ -35,4 +35,4 @@ FROM
         buyer_id > 100) t2 ON t1.leaf_categ_id = t2.leaf_categ_id
 GROUP BY t1.leaf_categ_id
 ORDER BY nums, leaf_categ_id
-limit 100
\ No newline at end of file
+limit 100;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query17.sql b/kylin-it/src/test/resources/query/sql_subquery/query17.sql
index 001bfa0..0a26460 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query17.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query17.sql
@@ -33,3 +33,4 @@ select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV
  
  where test_category_groupings.meta_categ_name  <> 'Baby'
  group by test_kylin_fact.lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query18.sql b/kylin-it/src/test/resources/query/sql_subquery/query18.sql
index 99d5aa9..9890386 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query18.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query18.sql
@@ -39,3 +39,4 @@ select test_kylin_fact.lstg_format_name, sum(test_kylin_fact.price) as GMV
  group by test_kylin_fact.lstg_format_name
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query19.sql b/kylin-it/src/test/resources/query/sql_subquery/query19.sql
index 55661d4..ed984cd 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query19.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query19.sql
@@ -36,3 +36,4 @@ select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV
  group by test_kylin_fact.lstg_format_name
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query21.sql b/kylin-it/src/test/resources/query/sql_subquery/query21.sql
index 6792b9b..0840145 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query21.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query21.sql
@@ -42,3 +42,4 @@ ON test_kylin_fact.cal_dt = xxx2.cal_dt
  group by test_kylin_fact.lstg_format_name
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query22.sql b/kylin-it/src/test/resources/query/sql_subquery/query22.sql
index b46424d..9601870 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query22.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query22.sql
@@ -41,3 +41,4 @@ ON test_kylin_fact.cal_dt = xxx2.cal_dt
  group by test_kylin_fact.lstg_format_name
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query23.sql b/kylin-it/src/test/resources/query/sql_subquery/query23.sql
index 224c295..77d44d8 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query23.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query23.sql
@@ -42,3 +42,4 @@ ON test_kylin_fact.cal_dt = xxx2.cal_dt
  group by test_kylin_fact.lstg_format_name
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query24.sql b/kylin-it/src/test/resources/query/sql_subquery/query24.sql
index af3f0d6..07f5508 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query24.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query24.sql
@@ -45,3 +45,4 @@ ON test_kylin_fact.cal_dt = xxx2.cal_dt
  group by test_kylin_fact.lstg_format_name
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query25.sql b/kylin-it/src/test/resources/query/sql_subquery/query25.sql
index db1072a..9a69bbc 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query25.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query25.sql
@@ -38,3 +38,4 @@ select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV
  group by test_kylin_fact.lstg_format_name
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query26.sql b/kylin-it/src/test/resources/query/sql_subquery/query26.sql
index e802b19..1b5b6b7 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query26.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query26.sql
@@ -32,3 +32,4 @@ select test_kylin_fact.lstg_format_name,sum(test_kylin_fact.price) as GMV
  
  where test_category_groupings.meta_categ_name  <> 'Baby'
  group by test_kylin_fact.lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query27.sql b/kylin-it/src/test/resources/query/sql_subquery/query27.sql
index b437279..a0c564c 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query27.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query27.sql
@@ -36,3 +36,4 @@ select test_kylin_fact.lstg_format_name, xxx.week_beg_dt , sum(test_kylin_fact.p
  group by test_kylin_fact.lstg_format_name, xxx.week_beg_dt 
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query28.sql b/kylin-it/src/test/resources/query/sql_subquery/query28.sql
index c1b20a7..55c3e4f 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query28.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query28.sql
@@ -37,3 +37,4 @@ select test_kylin_fact.lstg_format_name, xxx.week_beg_dt,xxx.cal_dt, sum(test_ky
  group by test_kylin_fact.lstg_format_name, xxx.week_beg_dt , xxx.cal_dt
 
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":342016}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query30.sql b/kylin-it/src/test/resources/query/sql_subquery/query30.sql
index 6018a48..4c52086 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query30.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query30.sql
@@ -31,3 +31,4 @@ on t1.cal_dt=test_cal_dt.cal_dt
 inner JOIN edw.test_sites as test_sites
 on t1.lstg_site_id = test_sites.site_id
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query31.sql b/kylin-it/src/test/resources/query/sql_subquery/query31.sql
index 5a1bdb5..ba2350f 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query31.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query31.sql
@@ -35,3 +35,4 @@ on t1.week_beg_dt=test_cal_dt.week_beg_dt
  
   on t1.lstg_site_id = test_sites.site_id
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":0}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query34.sql b/kylin-it/src/test/resources/query/sql_subquery/query34.sql
index 6389121..afb934b 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query34.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query34.sql
@@ -30,3 +30,4 @@
   
   group by case when '3'='1' then test_cal_dt.week_beg_dt  else   test_kylin_fact.cal_dt end
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_subquery/query37.sql b/kylin-it/src/test/resources/query/sql_subquery/query37.sql
index b96b544..0ef47bd 100644
--- a/kylin-it/src/test/resources/query/sql_subquery/query37.sql
+++ b/kylin-it/src/test/resources/query/sql_subquery/query37.sql
@@ -30,3 +30,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  )
  limit 1
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query00.sql b/kylin-it/src/test/resources/query/sql_tableau/query00.sql
index 5fb0117..2cafcb9 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query00.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query00.sql
@@ -23,3 +23,4 @@ select test_cal_dt.week_beg_dt, sum(test_kylin_fact.price)
  on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  group by test_cal_dt.week_beg_dt
 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query01.sql b/kylin-it/src/test/resources/query/sql_tableau/query01.sql
index cd0ebdf..ada4d52 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query01.sql
@@ -31,3 +31,4 @@ SELECT SUM(1) AS "COL",
  GROUP BY 2 
  HAVING COUNT(1)>0 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query02.sql b/kylin-it/src/test/resources/query/sql_tableau/query02.sql
index 75c384d..71a759d 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query02.sql
@@ -28,3 +28,4 @@ SELECT *
  having sum(price)>500 
  ) "TableauSQL" 
  LIMIT 1 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query03.sql b/kylin-it/src/test/resources/query/sql_tableau/query03.sql
index 26171ce..f74008e 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query03.sql
@@ -33,3 +33,4 @@ SELECT
  ,test_category_groupings.meta_categ_name 
  ,test_category_groupings.categ_lvl2_name 
  ,test_category_groupings.categ_lvl3_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query04.sql b/kylin-it/src/test/resources/query/sql_tableau/query04.sql
index 7c67108..88a4c60 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query04.sql
@@ -37,3 +37,4 @@ SELECT "TableauSQL"."META_CATEG_NAME" AS "none_META_CATEG_NAME_nk"
  ,test_category_groupings.categ_lvl3_name 
  ) "TableauSQL" 
  GROUP BY "TableauSQL"."META_CATEG_NAME" 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query05.sql b/kylin-it/src/test/resources/query/sql_tableau/query05.sql
index b499554..9755ca1 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query05.sql
@@ -38,3 +38,4 @@ SELECT SUM("TableauSQL"."GMV") AS "sum_GMV_ok",
  ,test_category_groupings.categ_lvl3_name 
  ) "TableauSQL" 
  HAVING (COUNT(1) > 0) 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query06.sql b/kylin-it/src/test/resources/query/sql_tableau/query06.sql
index b499554..9755ca1 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query06.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query06.sql
@@ -38,3 +38,4 @@ SELECT SUM("TableauSQL"."GMV") AS "sum_GMV_ok",
  ,test_category_groupings.categ_lvl3_name 
  ) "TableauSQL" 
  HAVING (COUNT(1) > 0) 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query07.sql b/kylin-it/src/test/resources/query/sql_tableau/query07.sql
index 5c137e3..ec432a4 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query07.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query07.sql
@@ -24,3 +24,4 @@ SELECT SUM("TableauSQL"."GMV") AS "sum_GMV_ok", SUM("TableauSQL"."TRANS_CNT") AS
  inner JOIN test_category_groupings ON test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id AND test_kylin_fact.lstg_site_id = test_category_groupings.site_id 
  group by test_cal_dt.week_beg_dt ,test_category_groupings.meta_categ_name ,test_category_groupings.categ_lvl2_name ,test_category_groupings.categ_lvl3_name 
  ) "TableauSQL" HAVING (COUNT(1) > 0) 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":376832}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query10.sql b/kylin-it/src/test/resources/query/sql_tableau/query10.sql
index cc5ec14..ec5df30 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query10.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query10.sql
@@ -23,3 +23,4 @@ SELECT "TEST_CAL_DT"."WEEK_BEG_DT" AS "none_WEEK_BEG_DT_nk",
  inner join test_category_groupings AS test_category_groupings
  on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  GROUP BY "TEST_CAL_DT"."WEEK_BEG_DT" 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query11.sql b/kylin-it/src/test/resources/query/sql_tableau/query11.sql
index 6cfeed4..9029238 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query11.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query11.sql
@@ -24,3 +24,4 @@ SELECT COUNT(1) AS cnt_ITEM_COUNT_ok,
  on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  GROUP BY "TEST_CAL_DT"."WEEK_BEG_DT" 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query12.sql b/kylin-it/src/test/resources/query/sql_tableau/query12.sql
index cc5ec14..ec5df30 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query12.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query12.sql
@@ -23,3 +23,4 @@ SELECT "TEST_CAL_DT"."WEEK_BEG_DT" AS "none_WEEK_BEG_DT_nk",
  inner join test_category_groupings AS test_category_groupings
  on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  GROUP BY "TEST_CAL_DT"."WEEK_BEG_DT" 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query13.sql b/kylin-it/src/test/resources/query/sql_tableau/query13.sql
index 4e1faaf..3c96e00 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query13.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query13.sql
@@ -22,3 +22,4 @@ SELECT EXTRACT(YEAR FROM TEST_CAL_DT.WEEK_BEG_DT) AS yr_WEEK_BEG_DT_ok
  inner join test_category_groupings AS test_category_groupings
  on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  GROUP BY EXTRACT(YEAR FROM TEST_CAL_DT.WEEK_BEG_DT) 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query14.sql b/kylin-it/src/test/resources/query/sql_tableau/query14.sql
index 23c790c..45faccd 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query14.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query14.sql
@@ -22,3 +22,4 @@ inner JOIN "EDW"."TEST_CAL_DT" AS "TEST_CAL_DT"  ON ("TEST_KYLIN_FACT"."CAL_DT"
  inner join test_category_groupings AS test_category_groupings
  on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and test_kylin_fact.lstg_site_id = test_category_groupings.site_id
 GROUP BY QUARTER("TEST_CAL_DT"."WEEK_BEG_DT"), EXTRACT(YEAR FROM "TEST_CAL_DT"."WEEK_BEG_DT") 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query15.sql b/kylin-it/src/test/resources/query/sql_tableau/query15.sql
index 198413c..a6f8b0b 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query15.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query15.sql
@@ -22,3 +22,4 @@ SELECT QUARTER(TEST_CAL_DT.WEEK_BEG_DT) AS qr_WEEK_BEG_DT_ok
  inner join test_category_groupings AS test_category_groupings
  on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  GROUP BY QUARTER(TEST_CAL_DT.WEEK_BEG_DT) 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query16.sql b/kylin-it/src/test/resources/query/sql_tableau/query16.sql
index 7140d8e..284dcc1 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query16.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query16.sql
@@ -23,3 +23,4 @@ SELECT EXTRACT(YEAR FROM TEST_CAL_DT.WEEK_BEG_DT) AS yr_WEEK_BEG_DT_ok, QUARTER(
  on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and test_kylin_fact.lstg_site_id = test_category_groupings.site_id
  GROUP BY EXTRACT(YEAR FROM TEST_CAL_DT.WEEK_BEG_DT), QUARTER(TEST_CAL_DT.WEEK_BEG_DT) 
  
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query17.sql b/kylin-it/src/test/resources/query/sql_tableau/query17.sql
index 5944ff9..c660efa 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query17.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query17.sql
@@ -22,3 +22,4 @@ inner JOIN EDW.TEST_CAL_DT AS TEST_CAL_DT ON ("TEST_KYLIN_FACT"."CAL_DT" = "TEST
  inner join test_category_groupings AS test_category_groupings
  on test_kylin_fact.leaf_categ_id = test_category_groupings.leaf_categ_id and test_kylin_fact.lstg_site_id = test_category_groupings.site_id
 GROUP BY EXTRACT(YEAR FROM "TEST_CAL_DT"."WEEK_BEG_DT"), QUARTER("TEST_CAL_DT"."WEEK_BEG_DT"), (( EXTRACT(YEAR FROM "TEST_CAL_DT"."WEEK_BEG_DT") * 100) + EXTRACT(MONTH FROM "TEST_CAL_DT"."WEEK_BEG_DT")), EXTRACT(MONTH FROM "TEST_CAL_DT"."WEEK_BEG_DT") 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query18.sql b/kylin-it/src/test/resources/query/sql_tableau/query18.sql
index 1b71bb0..5734cf9 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query18.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query18.sql
@@ -19,3 +19,4 @@
 select test_kylin_fact.lstg_format_name, sum(price) as GMV, count(price) as GMV_CNT
  from test_kylin_fact
  group by test_kylin_fact.lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query19.sql b/kylin-it/src/test/resources/query/sql_tableau/query19.sql
index c5c2856..5c9dcad 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query19.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query19.sql
@@ -24,3 +24,4 @@
  from test_kylin_fact 
  group by test_kylin_fact.lstg_format_name ) "TableauSQL" 
  GROUP BY "TableauSQL"."LSTG_FORMAT_NAME" 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query20.sql b/kylin-it/src/test/resources/query/sql_tableau/query20.sql
index f2f068a..72028e1 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query20.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query20.sql
@@ -24,3 +24,4 @@
  from test_kylin_fact where test_kylin_fact.lstg_format_name > 'ab'
  group by test_kylin_fact.lstg_format_name having count(price) > 2 ) "TableauSQL"
  GROUP BY "TableauSQL"."LSTG_FORMAT_NAME" 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query21.sql b/kylin-it/src/test/resources/query/sql_tableau/query21.sql
index 3e3208b..0a6c823 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query21.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query21.sql
@@ -25,3 +25,4 @@
  group by test_kylin_fact.lstg_format_name, test_cal_dt.week_beg_dt 
  having sum(price)>500
  limit 1
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query23.sql b/kylin-it/src/test/resources/query/sql_tableau/query23.sql
index 10430ab..6ce55f6 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query23.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query23.sql
@@ -21,3 +21,4 @@ select fact.cal_dt, sum(fact.price) from test_kylin_fact fact
 left join EDW.TEST_CAL_DT cal on fact.cal_dt=cal.cal_dt
 where cal.cal_dt  = date '2012-05-17' or cal.cal_dt  = date '2013-05-17'
 group by fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query24.sql b/kylin-it/src/test/resources/query/sql_tableau/query24.sql
index 29a69aa..e3f3f27 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query24.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query24.sql
@@ -22,3 +22,4 @@ left join EDW.TEST_CAL_DT AS TEST_CAL_DT on test_kylin_fact.cal_dt=test_cal_dt.c
 group by test_kylin_fact.cal_dt 
 order by 2 desc 
 limit 3
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query25.sql b/kylin-it/src/test/resources/query/sql_tableau/query25.sql
index cdc98b7..af5b12f 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query25.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query25.sql
@@ -26,3 +26,4 @@ SELECT "TEST_KYLIN_FACT"."CAL_DT", SUM("TEST_KYLIN_FACT"."PRICE") AS "sum_PRICE_
          INNER JOIN "EDW"."TEST_CAL_DT" AS "TEST_CAL_DT" ON ("TEST_KYLIN_FACT"."CAL_DT" = "TEST_CAL_DT"."CAL_DT")
      GROUP BY "TEST_KYLIN_FACT"."CAL_DT"   ORDER BY 2 DESC   LIMIT 10  ) "t0" ON ("TEST_KYLIN_FACT"."CAL_DT" = "t0"."none_CAL_DT_ok") 
     GROUP BY "TEST_KYLIN_FACT"."CAL_DT"
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query27.sql b/kylin-it/src/test/resources/query/sql_tableau/query27.sql
index beeb168..97ecdee 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query27.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query27.sql
@@ -22,3 +22,4 @@ SELECT "TEST_KYLIN_FACT"."CAL_DT", SUM("TEST_KYLIN_FACT"."PRICE") AS "sum_PRICE_
              GROUP BY "TEST_KYLIN_FACT"."CAL_DT"   ORDER BY 2 DESC   LIMIT 7  )
 
     "t0" ON ("TEST_KYLIN_FACT"."CAL_DT" = "t0"."none_CAL_DT_ok") GROUP BY "TEST_KYLIN_FACT"."CAL_DT"
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query28.sql b/kylin-it/src/test/resources/query/sql_tableau/query28.sql
index 48cc342..4240d12 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query28.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query28.sql
@@ -21,3 +21,4 @@
 select lstg_format_name, avg(price) as GMV
  from test_kylin_fact 
  group by lstg_format_name 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query29.sql b/kylin-it/src/test/resources/query/sql_tableau/query29.sql
index 0858087..d116a39 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query29.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query29.sql
@@ -27,3 +27,4 @@ SELECT *
  group by test_kylin_fact.lstg_format_name, test_cal_dt.week_beg_dt 
  ) "TableauSQL" 
  LIMIT 1 
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_tableau/query67.sql b/kylin-it/src/test/resources/query/sql_tableau/query67.sql
index 25cc110..c74f8c8 100644
--- a/kylin-it/src/test/resources/query/sql_tableau/query67.sql
+++ b/kylin-it/src/test/resources/query/sql_tableau/query67.sql
@@ -21,3 +21,4 @@ SELECT (CASE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" WHEN 'Auction' THEN '111' ELSE
 FROM "TEST_KYLIN_FACT" "TEST_KYLIN_FACT"
 --group by (CASE "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME" WHEN 'Auction' THEN '111' ELSE '222' END)  ORDER BY 1 ASC
 GROUP BY "TEST_KYLIN_FACT"."LSTG_FORMAT_NAME"  ORDER BY 1 ASC
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query01.sql b/kylin-it/src/test/resources/query/sql_timestamp/query01.sql
index 08e13a2..f4bebf3 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query01.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query02.sql b/kylin-it/src/test/resources/query/sql_timestamp/query02.sql
index f372212..f9cf63a 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query02.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query03.sql b/kylin-it/src/test/resources/query/sql_timestamp/query03.sql
index 0dc76bd..b977573 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query03.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query05.sql b/kylin-it/src/test/resources/query/sql_timestamp/query05.sql
index 171f473..fb9ef19 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query05.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query11.sql b/kylin-it/src/test/resources/query/sql_timestamp/query11.sql
index edb3d54..c0e64e3 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query11.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query11.sql
@@ -19,3 +19,4 @@ SELECT sum(price)  as sum_price
  FROM TEST_KYLIN_FACT 
  WHERE CAL_DT > cast(TIMESTAMPADD(Day, -15000, CURRENT_DATE) as DATE)
 GROUP BY CAL_DT
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query12.sql b/kylin-it/src/test/resources/query/sql_timestamp/query12.sql
index 73b432f..f4ba720 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query12.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query12.sql
@@ -19,3 +19,4 @@ SELECT sum(price)  as sum_price
  FROM TEST_KYLIN_FACT 
  WHERE CAL_DT > cast(TIMESTAMPADD(Day, -2000, CURRENT_DATE) as DATE)
 GROUP BY CAL_DT
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query13.sql b/kylin-it/src/test/resources/query/sql_timestamp/query13.sql
index fed0b73..4f87878 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query13.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query13.sql
@@ -19,3 +19,4 @@ SELECT sum(price)  as sum_price
  FROM TEST_KYLIN_FACT 
  WHERE CAL_DT > cast(TIMESTAMPADD(Day, -0, CURRENT_TIMESTAMP) as DATE)
 GROUP BY CAL_DT
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query14.sql b/kylin-it/src/test/resources/query/sql_timestamp/query14.sql
index 40378b9..b03d996 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query14.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query14.sql
@@ -19,3 +19,4 @@ SELECT sum(price)  as sum_price
  FROM TEST_KYLIN_FACT 
  WHERE CAL_DT > cast(TIMESTAMPADD(Day, -15000, CURRENT_TIMESTAMP ) as DATE)
 GROUP BY CAL_DT
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query21.sql b/kylin-it/src/test/resources/query/sql_timestamp/query21.sql
index d1b8945..c92a90a 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query21.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query21.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query21_a.sql b/kylin-it/src/test/resources/query/sql_timestamp/query21_a.sql
index 1d4d617..9f4ba7e 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query21_a.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query21_a.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query22.sql b/kylin-it/src/test/resources/query/sql_timestamp/query22.sql
index 34524c2..0049604 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query22.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query22.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query22_a.sql b/kylin-it/src/test/resources/query/sql_timestamp/query22_a.sql
index d68a354..0da1f86 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query22_a.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query22_a.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query22_b.sql b/kylin-it/src/test/resources/query/sql_timestamp/query22_b.sql
index 4d4fa98..dbc86b2 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query22_b.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query22_b.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query22_c.sql b/kylin-it/src/test/resources/query/sql_timestamp/query22_c.sql
index d8e8096..ffecccd 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query22_c.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query22_c.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query22_d.sql b/kylin-it/src/test/resources/query/sql_timestamp/query22_d.sql
index 5bf36dd..91be5cb 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query22_d.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query22_d.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query22_e.sql b/kylin-it/src/test/resources/query/sql_timestamp/query22_e.sql
index bb36d83..8c6b6c6 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query22_e.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query22_e.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query23.sql b/kylin-it/src/test/resources/query/sql_timestamp/query23.sql
index 9050894..b603103 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query23.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query23.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query23_a.sql b/kylin-it/src/test/resources/query/sql_timestamp/query23_a.sql
index f3f7141..28a71b8 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query23_a.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query23_a.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query25.sql b/kylin-it/src/test/resources/query/sql_timestamp/query25.sql
index 2fb8b23..ead8836 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query25.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query25.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query25_a.sql b/kylin-it/src/test/resources/query/sql_timestamp/query25_a.sql
index 2034f19..1aaa418 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query25_a.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query25_a.sql
@@ -26,3 +26,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  GROUP BY test_kylin_fact.cal_dt
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_timestamp/query26.sql b/kylin-it/src/test/resources/query/sql_timestamp/query26.sql
index 36abad1..244dd17 100644
--- a/kylin-it/src/test/resources/query/sql_timestamp/query26.sql
+++ b/kylin-it/src/test/resources/query/sql_timestamp/query26.sql
@@ -23,3 +23,4 @@ SELECT count(*) as cnt
  INNER JOIN TEST_CATEGORY_GROUPINGS as TEST_CATEGORY_GROUPINGS
  ON TEST_KYLIN_FACT.LEAF_CATEG_ID = TEST_CATEGORY_GROUPINGS.LEAF_CATEG_ID AND TEST_KYLIN_FACT.LSTG_SITE_ID = TEST_CATEGORY_GROUPINGS.SITE_ID
  where TEST_TIME_ENC >= TIMESTAMP'2010-01-01 15:43:38'
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":788464}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_topn/query45.sql b/kylin-it/src/test/resources/query/sql_topn/query45.sql
index 8940c2e..abf26c7 100644
--- a/kylin-it/src/test/resources/query/sql_topn/query45.sql
+++ b/kylin-it/src/test/resources/query/sql_topn/query45.sql
@@ -21,3 +21,4 @@
 select seller_id, sum(price) as s from test_kylin_fact
   where lstg_format_name='FP-GTC' 
   group by seller_id order by s desc limit 10
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_topn/query81.sql b/kylin-it/src/test/resources/query/sql_topn/query81.sql
index 1fedef8..beab110 100644
--- a/kylin-it/src/test/resources/query/sql_topn/query81.sql
+++ b/kylin-it/src/test/resources/query/sql_topn/query81.sql
@@ -25,4 +25,4 @@ inner JOIN edw.test_cal_dt as test_cal_dt
  inner JOIN edw.test_sites as test_sites
  ON test_kylin_fact.lstg_site_id = test_sites.site_id
  where test_cal_dt.week_beg_dt between DATE '2013-09-01' and DATE '2013-10-01' and (lstg_format_name='FP-GTC' or 'a' = 'b')
- group by test_cal_dt.week_beg_dt, test_kylin_fact.seller_id order by GMV desc limit 10
\ No newline at end of file
+ group by test_cal_dt.week_beg_dt, test_kylin_fact.seller_id order by GMV desc limit 10;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_topn/query82.sql b/kylin-it/src/test/resources/query/sql_topn/query82.sql
index 57e9de0..923dde2 100644
--- a/kylin-it/src/test/resources/query/sql_topn/query82.sql
+++ b/kylin-it/src/test/resources/query/sql_topn/query82.sql
@@ -25,3 +25,4 @@ select  test_kylin_fact.cal_dt, seller_id
  AND test_kylin_fact.lstg_site_id = test_category_groupings.site_id 
  group by 
  test_kylin_fact.cal_dt, test_kylin_fact.seller_id order by sum(test_kylin_fact.price) desc limit 20
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_topn/query83.sql b/kylin-it/src/test/resources/query/sql_topn/query83.sql
index 514beb4..1542501 100644
--- a/kylin-it/src/test/resources/query/sql_topn/query83.sql
+++ b/kylin-it/src/test/resources/query/sql_topn/query83.sql
@@ -27,3 +27,4 @@ SELECT
  where test_kylin_fact.cal_dt < DATE '2013-02-01' 
  group by 
  test_kylin_fact.seller_id order by sum(test_kylin_fact.price) desc limit 20
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":262144}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_union/query01.sql b/kylin-it/src/test/resources/query/sql_union/query01.sql
index d5ff53f..4acb105 100644
--- a/kylin-it/src/test/resources/query/sql_union/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_union/query01.sql
@@ -11,3 +11,4 @@ join (
 ) TEST_B
 on TEST_A.ORDER_ID = TEST_B.ORDER_ID
 group by TEST_A.SELLER_ID
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_union/query02.sql b/kylin-it/src/test/resources/query/sql_union/query02.sql
index db7e29a..c5354f7 100644
--- a/kylin-it/src/test/resources/query/sql_union/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_union/query02.sql
@@ -8,3 +8,4 @@ join (
 ) TEST_B
 on TEST_A.ORDER_ID = TEST_B.ORDER_ID
 group by TEST_A.SELLER_ID
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_union/query03.sql b/kylin-it/src/test/resources/query/sql_union/query03.sql
index 962fb6b..4754c41 100644
--- a/kylin-it/src/test/resources/query/sql_union/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_union/query03.sql
@@ -22,3 +22,4 @@ inner join (
 ) TEST_B
 on TEST_A.seller_id = TEST_B.seller_id
 group by TEST_A.seller_id
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":1310735}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query00.sql b/kylin-it/src/test/resources/query/sql_window/query00.sql
index 2e49cd9..600ce6e 100644
--- a/kylin-it/src/test/resources/query/sql_window/query00.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query00.sql
@@ -18,3 +18,4 @@
 select lstg_format_name, sum(price) as GMV, row_number() over(order by lstg_format_name)
 from test_kylin_fact
 group by lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":14336}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query01.sql b/kylin-it/src/test/resources/query/sql_window/query01.sql
index 9bc8b23..7f6cbbd 100644
--- a/kylin-it/src/test/resources/query/sql_window/query01.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query01.sql
@@ -18,3 +18,4 @@
 select lstg_format_name, sum(price) as GMV, count(lstg_format_name) over(partition by lstg_format_name)
 from test_kylin_fact
 group by cal_dt, lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query02.sql b/kylin-it/src/test/resources/query/sql_window/query02.sql
index 0c1b953..e4fe7c0 100644
--- a/kylin-it/src/test/resources/query/sql_window/query02.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query02.sql
@@ -18,3 +18,4 @@
 select lstg_format_name, avg(sum(price)) over(partition by lstg_format_name)
 from test_kylin_fact
 group by cal_dt, lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query03.sql b/kylin-it/src/test/resources/query/sql_window/query03.sql
index da02cc0..12c0188 100644
--- a/kylin-it/src/test/resources/query/sql_window/query03.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query03.sql
@@ -20,4 +20,4 @@ sum(sum(price)) over(partition by lstg_format_name),
 max(sum(price)) over(partition by lstg_format_name),
 min(sum(price)) over(partition by lstg_format_name)
 from test_kylin_fact
-group by cal_dt, lstg_format_name
\ No newline at end of file
+group by cal_dt, lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query04.sql b/kylin-it/src/test/resources/query/sql_window/query04.sql
index f5ed7b5..0e1030e 100644
--- a/kylin-it/src/test/resources/query/sql_window/query04.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query04.sql
@@ -20,3 +20,4 @@ rank() over(partition by lstg_format_name order by cal_dt) as "RANK",
 dense_rank() over(partition by lstg_format_name order by cal_dt) as "DENSE_RANK"
 from test_kylin_fact
 group by cal_dt, lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query05.sql b/kylin-it/src/test/resources/query/sql_window/query05.sql
index c1555fd..52419d7 100644
--- a/kylin-it/src/test/resources/query/sql_window/query05.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query05.sql
@@ -24,3 +24,4 @@ ntile(4) over (partition by lstg_format_name order by cal_dt) as "quarter"
 from test_kylin_fact
 where cal_dt < '2012-02-01'
 group by cal_dt, lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query06.sql b/kylin-it/src/test/resources/query/sql_window/query06.sql
index d79243b..56ddd90 100644
--- a/kylin-it/src/test/resources/query/sql_window/query06.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query06.sql
@@ -21,3 +21,4 @@ when 0.0 then 0 else sum(price)/lag(sum(price), 1, 0.0) over(partition by lstg_f
 from test_kylin_fact
 where cal_dt < '2012-02-01'
 group by cal_dt, lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query07.sql b/kylin-it/src/test/resources/query/sql_window/query07.sql
index 8eb0d77..369cc5a 100644
--- a/kylin-it/src/test/resources/query/sql_window/query07.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query07.sql
@@ -21,3 +21,4 @@ last_value(sum(price)) over (partition by lstg_format_name order by cal_dt rows
 from test_kylin_fact
 where cal_dt < '2012-02-01'
 group by cal_dt, lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query08.sql b/kylin-it/src/test/resources/query/sql_window/query08.sql
index 828932f..ac96df1 100644
--- a/kylin-it/src/test/resources/query/sql_window/query08.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query08.sql
@@ -21,3 +21,4 @@ last_value(sum(price)) over (partition by lstg_format_name order by cast(cal_dt
 from test_kylin_fact
 where cal_dt < '2012-02-01'
 group by cal_dt, lstg_format_name
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query09.sql b/kylin-it/src/test/resources/query/sql_window/query09.sql
index 7a8542a..d1b8aba 100644
--- a/kylin-it/src/test/resources/query/sql_window/query09.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query09.sql
@@ -24,3 +24,4 @@ select * from(
   group by cal_dt, lstg_format_name
 )t
 where cal_dt between '2013-01-06' and '2013-01-15'
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query11.sql b/kylin-it/src/test/resources/query/sql_window/query11.sql
index 3002f4c..5941b46 100644
--- a/kylin-it/src/test/resources/query/sql_window/query11.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query11.sql
@@ -20,4 +20,4 @@ sum(sum(price)) over(partition by lstg_format_name,cal_dt),
 max(sum(price)) over(partition by lstg_format_name,cal_dt),
 min(sum(price)) over(partition by lstg_format_name)
 from test_kylin_fact
-group by cal_dt, lstg_format_name
\ No newline at end of file
+group by cal_dt, lstg_format_name;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query12.sql b/kylin-it/src/test/resources/query/sql_window/query12.sql
index fb89df2..8ccc4b2 100644
--- a/kylin-it/src/test/resources/query/sql_window/query12.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query12.sql
@@ -23,3 +23,4 @@ select * from (  select cal_dt, lstg_format_name, sum(price) as GMV,
   group by cal_dt, lstg_format_name,SLR_SEGMENT_CD
 )t
 where cal_dt between '2013-01-06' and '2013-01-15'
+;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":276480}
\ No newline at end of file
diff --git a/kylin-it/src/test/resources/query/sql_window/query13.sql b/kylin-it/src/test/resources/query/sql_window/query13.sql
index 9807fd6..46db831 100644
--- a/kylin-it/src/test/resources/query/sql_window/query13.sql
+++ b/kylin-it/src/test/resources/query/sql_window/query13.sql
@@ -19,4 +19,4 @@ select t.first_seller_id as first_seller_id_test, count(*) from (
 select first_value(seller_id) over (partition by buyer_id) as first_seller_id
 from test_kylin_fact inner join test_order on test_kylin_fact.order_id=test_order.order_id
 )
-as t group by t.first_seller_id
\ No newline at end of file
+as t group by t.first_seller_id;{"scanRowCount":0,"scanBytes":0,"scanFiles":0,"cuboidId":2097151}
\ No newline at end of file
diff --git a/kylin-spark-project/kylin-spark-query/src/main/scala/org/apache/spark/sql/KylinSession.scala b/kylin-spark-project/kylin-spark-query/src/main/scala/org/apache/spark/sql/KylinSession.scala
index e0229bf..fb09d38 100644
--- a/kylin-spark-project/kylin-spark-query/src/main/scala/org/apache/spark/sql/KylinSession.scala
+++ b/kylin-spark-project/kylin-spark-query/src/main/scala/org/apache/spark/sql/KylinSession.scala
@@ -151,7 +151,7 @@ object KylinSession extends Logging {
         sparkConf.set("hive.metastore.sasl.enabled", "true")
       }
 
-      conf.getSparkConf.asScala.foreach {
+      conf.getQuerySparkConf.asScala.foreach {
         case (k, v) =>
           sparkConf.set(k, v)
       }
diff --git a/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/BuildAndQueryEmptySegmentsTest.java b/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/BuildAndQueryEmptySegmentsTest.java
index f3843d1..e5b2592 100644
--- a/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/BuildAndQueryEmptySegmentsTest.java
+++ b/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/BuildAndQueryEmptySegmentsTest.java
@@ -18,6 +18,7 @@
 package org.apache.kylin.engine.spark2;
 
 import org.apache.kylin.common.KylinConfig;
+import org.apache.kylin.common.util.Pair;
 import org.apache.kylin.cube.CubeManager;
 import org.apache.kylin.engine.spark.LocalWithSparkSessionTest;
 import org.apache.kylin.job.exception.SchedulerException;
@@ -25,6 +26,7 @@ import org.apache.kylin.job.execution.ExecutableManager;
 import org.apache.kylin.metadata.model.SegmentRange;
 import org.apache.spark.sql.Dataset;
 import org.apache.spark.sql.KylinSparkEnv;
+import org.apache.spark.sql.Row;
 import org.apache.spark.sql.common.SparkQueryTest;
 import org.junit.Assert;
 import org.junit.Test;
@@ -67,23 +69,23 @@ public class BuildAndQueryEmptySegmentsTest extends LocalWithSparkSessionTest {
     }
 
     private void testQuery(String sqlStr) {
-        Dataset dsFromCube = NExecAndComp.sql(getProject(), sqlStr);
-        Assert.assertEquals(1L, dsFromCube.count());
+        Pair<Dataset<Row>, NExecAndComp.ITQueryMetrics> pair = NExecAndComp.sql(getProject(), sqlStr);
+        Assert.assertEquals(1L, pair.getFirst().count());
 
         Dataset dsFromSpark = NExecAndComp.querySparkSql(sqlStr);
         Assert.assertEquals(1L, dsFromSpark.count());
-        String msg = SparkQueryTest.checkAnswer(dsFromCube, dsFromSpark, false);
+        String msg = SparkQueryTest.checkAnswer(pair.getFirst(), dsFromSpark, false);
         Assert.assertNotNull(msg);
     }
 
     private void testQueryUnequal(String sqlStr) {
 
-        Dataset dsFromCube = NExecAndComp.sql(getProject(), sqlStr);
-        Assert.assertEquals(1L, dsFromCube.count());
+        Pair<Dataset<Row>, NExecAndComp.ITQueryMetrics> pair = NExecAndComp.sql(getProject(), sqlStr);
+        Assert.assertEquals(1L, pair.getFirst().count());
 
         Dataset dsFromSpark = NExecAndComp.querySparkSql(sqlStr);
         Assert.assertEquals(1L, dsFromSpark.count());
-        String msg = SparkQueryTest.checkAnswer(dsFromCube, dsFromSpark, false);
+        String msg = SparkQueryTest.checkAnswer(pair.getFirst(), dsFromSpark, false);
         Assert.assertNotNull(msg);
     }
 
diff --git a/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/NBuildAndQueryTest.java b/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/NBuildAndQueryTest.java
index f217541..fd70f9b 100644
--- a/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/NBuildAndQueryTest.java
+++ b/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/NBuildAndQueryTest.java
@@ -21,6 +21,7 @@ import org.apache.kylin.shaded.com.google.common.collect.Maps;
 import java.util.Map;
 import org.apache.kylin.common.KylinConfig;
 import org.apache.kylin.common.util.Pair;
+import org.apache.kylin.common.util.Triple;
 import org.apache.kylin.cube.CubeManager;
 import org.apache.kylin.cube.CubeSegment;
 import org.apache.kylin.engine.spark.LocalWithSparkSessionTest;
@@ -98,7 +99,7 @@ public class NBuildAndQueryTest extends LocalWithSparkSessionTest {
         populateSSWithCSVData(config, getProject(), KylinSparkEnv.getSparkSession());
 
         // 3. Compare Kylin with Spark
-        List<QueryCallable> tasks = prepareAndGenQueryTasks(config);
+        List<QueryCallable> tasks = prepareAndGenQueryTasks();
         List<Pair<String, Throwable>> results = execAndGetResults(tasks);
         Assert.assertEquals(results.size(), tasks.size());
         report(results);
@@ -145,7 +146,7 @@ public class NBuildAndQueryTest extends LocalWithSparkSessionTest {
         }
     }
 
-    private List<QueryCallable> prepareAndGenQueryTasks(KylinConfig config) throws Exception {
+    private List<QueryCallable> prepareAndGenQueryTasks() throws Exception {
         String[] joinTypes = new String[] {"left"};
         List<QueryCallable> tasks = new ArrayList<>();
         for (String joinType : joinTypes) {
@@ -292,9 +293,9 @@ public class NBuildAndQueryTest extends LocalWithSparkSessionTest {
                             .fetchQueries(KYLIN_SQL_BASE_DIR + File.separator + "sql");
                     NExecAndComp.execLimitAndValidate(queries, getProject(), joinType);
                 } else {
-                    List<Pair<String, String>> queries = NExecAndComp
-                            .fetchQueries(KYLIN_SQL_BASE_DIR + File.separator + sqlFolder);
-                    NExecAndComp.execAndCompare(queries, getProject(), compareLevel, joinType);
+                    List<Triple<String, String, NExecAndComp.ITQueryMetrics>> queries = NExecAndComp
+                            .fetchQueries2(KYLIN_SQL_BASE_DIR + File.separator + sqlFolder);
+                    NExecAndComp.execAndCompareNew2(queries, getProject(), compareLevel, joinType, null);
                 }
             } catch (Throwable th) {
                 logger.error("Query fail on: {}", identity);
diff --git a/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/NExecAndComp.java b/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/NExecAndComp.java
index 9ab8fe9..be54c76 100644
--- a/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/NExecAndComp.java
+++ b/kylin-spark-project/kylin-spark-test/src/test/java/org/apache/kylin/engine/spark2/NExecAndComp.java
@@ -17,18 +17,24 @@
  */
 package org.apache.kylin.engine.spark2;
 
-import org.apache.kylin.shaded.com.google.common.base.Preconditions;
-import org.apache.kylin.shaded.com.google.common.collect.Lists;
-import org.apache.kylin.shaded.com.google.common.collect.Sets;
+import com.fasterxml.jackson.databind.DeserializationFeature;
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.google.common.base.Preconditions;
+import com.google.common.collect.Lists;
+import com.google.common.collect.Sets;
 import org.apache.commons.io.FileUtils;
 import org.apache.commons.lang3.StringUtils;
+import org.apache.kylin.common.QueryContext;
 import org.apache.kylin.common.QueryContextFacade;
 import org.apache.kylin.common.util.DBUtils;
 import org.apache.kylin.common.util.Pair;
+import org.apache.kylin.common.util.Triple;
 import org.apache.kylin.engine.spark2.utils.QueryUtil;
 import org.apache.kylin.engine.spark2.utils.RecAndQueryCompareUtil.CompareEntity;
+import org.apache.kylin.metadata.querymeta.SelectedColumnMeta;
 import org.apache.kylin.query.QueryConnection;
 import org.apache.kylin.query.relnode.OLAPContext;
+import org.apache.kylin.rest.response.SQLResponse;
 import org.apache.spark.sql.Dataset;
 import org.apache.spark.sql.KylinSparkEnv;
 import org.apache.spark.sql.Row;
@@ -42,6 +48,7 @@ import java.nio.charset.Charset;
 import java.sql.Connection;
 import java.sql.PreparedStatement;
 import java.sql.ResultSet;
+import java.sql.ResultSetMetaData;
 import java.sql.SQLException;
 import java.sql.Statement;
 import java.util.ArrayList;
@@ -64,6 +71,8 @@ public class NExecAndComp {
         NONE, // Do not compare and just return OK
     }
 
+    private static ObjectMapper objectMapper = new ObjectMapper();
+
     static void execLimitAndValidate(List<Pair<String, String>> queries, String prj, String joinType) {
         execLimitAndValidateNew(queries, prj, joinType, null);
     }
@@ -82,8 +91,9 @@ public class NExecAndComp {
                 appendLimitQueries++;
             }
 
-            Dataset<Row> kylinResult = (recAndQueryResult == null) ? queryWithKylin(prj, joinType, sqlAndAddedLimitSql)
+            Pair<Dataset<Row>, ITQueryMetrics> queryResult = (recAndQueryResult == null) ? queryWithKylin(prj, joinType, sqlAndAddedLimitSql)
                     : queryWithKylin(prj, joinType, sqlAndAddedLimitSql, recAndQueryResult);
+            Dataset<Row> kylinResult = queryResult.getFirst();
             addQueryPath(recAndQueryResult, query, sql);
             Dataset<Row> sparkResult = queryWithSpark(prj, sql, query.getFirst());
             List<Row> kylinRows = SparkQueryTest.castDataType(kylinResult, sparkResult).toJavaRDD().collect();
@@ -116,9 +126,63 @@ public class NExecAndComp {
 
             // Query from Cube
             long startTime = System.currentTimeMillis();
-            Dataset<Row> cubeResult = (recAndQueryResult == null) ? queryWithKylin(prj, joinType, Pair.newPair(sql, sql))
+            Pair<Dataset<Row>, ITQueryMetrics> queryResult = (recAndQueryResult == null) ? queryWithKylin(prj, joinType, Pair.newPair(sql, sql))
                     : queryWithKylin(prj, joinType, Pair.newPair(sql, sql), recAndQueryResult);
             addQueryPath(recAndQueryResult, query, sql);
+            Dataset<Row> cubeResult = queryResult.getFirst();
+            if (compareLevel == CompareLevel.SAME) {
+                Dataset<Row> sparkResult = null;
+                String csvDataPathStr = query.getFirst() + ".expected";
+                if(new File(csvDataPathStr).exists()) {
+                    logger.debug("Use expected dataset for {}", sql);
+                    sparkResult = KylinSparkEnv.getSparkSession().read().csv(csvDataPathStr);
+                } else {
+                    sparkResult = queryWithSpark(prj, sql, query.getFirst());
+                }
+                String result = SparkQueryTest.checkAnswer(SparkQueryTest.castDataType(cubeResult, sparkResult), sparkResult, false);
+                if (result != null) {
+                    logger.error("Failed on compare query ({}) :{}", joinType, query);
+                    logger.error(result);
+                    throw new IllegalArgumentException("query (" + joinType + ") :" + query + " result not match");
+                } else {
+                    logger.debug("Passed {}", query.getFirst());
+                }
+            } else if (compareLevel == CompareLevel.NONE) {
+                Dataset<Row> sparkResult = queryWithSpark(prj, sql, query.getFirst());
+                List<Row> sparkRows = sparkResult.toJavaRDD().collect();
+                List<Row> kylinRows = SparkQueryTest.castDataType(cubeResult, sparkResult).toJavaRDD().collect();
+                if (compareResults(normRows(sparkRows), normRows(kylinRows), compareLevel)) {
+                    logger.error("Failed on compare query ({}) :{}", joinType, query);
+                    throw new IllegalArgumentException("query (" + joinType + ") :" + query + " result not match");
+                }
+            } else {
+                cubeResult.persist();
+                logger.info(
+                        "result comparision is not available for {}, part of the cube results: {},\n {}" , query.getFirst(),
+                        cubeResult.count(), cubeResult.showString(20, 25 , false));
+                cubeResult.unpersist();
+            }
+            logger.trace("The query ({}) : {} cost {} (ms)", query.getFirst(), "", System.currentTimeMillis() - startTime);
+        }
+    }
+
+    public static void execAndCompareNew2(List<Triple<String, String, ITQueryMetrics>> queries, String prj, CompareLevel compareLevel,
+                                         String joinType, Map<String, CompareEntity> recAndQueryResult) throws IOException{
+        for (Triple<String, String, ITQueryMetrics> query : queries) {
+            logger.info("Exec and compare query ({}) :{}", joinType, query.getFirst());
+            String sql = changeJoinType(query.getSecond(), joinType);
+
+            // Query from Cube
+            long startTime = System.currentTimeMillis();
+            Pair<Dataset<Row>, ITQueryMetrics> queryResult = (recAndQueryResult == null) ? queryWithKylin(prj, joinType, Pair.newPair(sql, sql))
+                    : queryWithKylin(prj, joinType, Pair.newPair(sql, sql), recAndQueryResult);
+            ITQueryMetrics collectedMetrics = queryResult.getSecond();
+            Dataset<Row> cubeResult = queryResult.getFirst();
+            if(!checkQueryMetrics(query.getThird(), collectedMetrics)) {
+                logger.error("Query metrics! Please check you SQL:" + sql);
+                throw new IllegalArgumentException("Query metrics not match!");
+            }
+            addQueryPath2(recAndQueryResult, query.getFirst(), sql);
 
             if (compareLevel == CompareLevel.SAME) {
                 Dataset<Row> sparkResult = null;
@@ -156,6 +220,10 @@ public class NExecAndComp {
         }
     }
 
+    public static boolean checkQueryMetrics(ITQueryMetrics comparedMetrics, ITQueryMetrics collectedMetrics) {
+        return comparedMetrics.equals(collectedMetrics);
+    }
+
     public static boolean execAndCompareQueryResult(Pair<String, String> queryForKylin,
                                                     Pair<String, String> queryForSpark, String joinType, String prj,
                                                     Map<String, CompareEntity> recAndQueryResult) {
@@ -165,8 +233,8 @@ public class NExecAndComp {
         List<Row> sparkRows = sparkResult.toJavaRDD().collect();
 
         String sqlForKylin = changeJoinType(queryForKylin.getSecond(), joinType);
-        Dataset<Row> cubeResult = queryWithKylin(prj, joinType, Pair.newPair(sqlForKylin, sqlForKylin));
-        List<Row> kylinRows = SparkQueryTest.castDataType(cubeResult, sparkResult).toJavaRDD().collect();
+        Pair<Dataset<Row>, ITQueryMetrics> pair = queryWithKylin(prj, joinType, Pair.newPair(sqlForKylin, sqlForKylin));
+        List<Row> kylinRows = SparkQueryTest.castDataType(pair.getFirst(), sparkResult).toJavaRDD().collect();
 
         return sparkRows.equals(kylinRows);
     }
@@ -189,25 +257,35 @@ public class NExecAndComp {
         recAndQueryResult.get(modifiedSql).setFilePath(query.getFirst());
     }
 
+    private static void addQueryPath2(Map<String, CompareEntity> recAndQueryResult, String filePath,
+                                     String modifiedSql) {
+        if (recAndQueryResult == null) {
+            return;
+        }
+
+        Preconditions.checkState(recAndQueryResult.containsKey(modifiedSql));
+        recAndQueryResult.get(modifiedSql).setFilePath(filePath);
+    }
+
     @Deprecated
     static void execCompareQueryAndCompare(List<Pair<String, String>> queries, String prj, String joinType) {
         throw new IllegalStateException(
                 "The method has deprecated, please call org.apache.kylin.engine.spark2.NExecAndComp.execAndCompareNew");
     }
 
-    private static Dataset<Row> queryWithKylin(String prj, String joinType, Pair<String, String> pair,
+    private static Pair<Dataset<Row>, ITQueryMetrics> queryWithKylin(String prj, String joinType, Pair<String, String> pair,
                                                Map<String, CompareEntity> compareEntityMap) {
 
         compareEntityMap.putIfAbsent(pair.getFirst(), new CompareEntity());
         final CompareEntity entity = compareEntityMap.get(pair.getFirst());
         entity.setSql(pair.getFirst());
-        Dataset<Row> rowDataset = queryFromCube(prj, changeJoinType(pair.getSecond(), joinType));
+        Pair<Dataset<Row>, ITQueryMetrics> queryResult = queryFromCube(prj, changeJoinType(pair.getSecond(), joinType));
         entity.setOlapContexts(OLAPContext.getThreadLocalContexts());
         OLAPContext.clearThreadLocalContexts();
-        return rowDataset;
+        return queryResult;
     }
 
-    private static Dataset<Row> queryWithKylin(String prj, String joinType, Pair<String, String> sql) {
+    private static Pair<Dataset<Row>, ITQueryMetrics> queryWithKylin(String prj, String joinType, Pair<String, String> sql) {
         return queryFromCube(prj, changeJoinType(sql.getSecond(), joinType));
     }
 
@@ -247,6 +325,11 @@ public class NExecAndComp {
         return retrieveITSqls(sqlFolder);
     }
 
+    public static List<Triple<String, String, ITQueryMetrics>> fetchQueries2(String folder) throws IOException {
+        File sqlFolder = new File(folder);
+        return retrieveITSqls2(sqlFolder);
+    }
+
     public static List<Pair<String, String>> fetchPartialQueries(String folder, int start, int end) throws IOException {
         File sqlFolder = new File(folder);
         List<Pair<String, String>> originalSqls = retrieveITSqls(sqlFolder);
@@ -297,6 +380,40 @@ public class NExecAndComp {
         return ret;
     }
 
+    private static List<Triple<String, String, ITQueryMetrics>> retrieveITSqls2(File file) throws IOException {
+        File[] sqlFiles = new File[0];
+        if (file != null && file.exists() && file.listFiles() != null) {
+            sqlFiles = file.listFiles((dir, name) -> name.endsWith(".sql"));
+        }
+        List<Triple<String, String, ITQueryMetrics>> ret = Lists.newArrayList();
+        assert sqlFiles != null;
+        Arrays.sort(sqlFiles, (o1, o2) -> {
+            final String idxStr1 = o1.getName().replaceAll("\\D", "");
+            final String idxStr2 = o2.getName().replaceAll("\\D", "");
+            if (idxStr1.isEmpty() || idxStr2.isEmpty()) {
+                return String.CASE_INSENSITIVE_ORDER.compare(o1.getName(), o2.getName());
+            }
+            return Integer.parseInt(idxStr1) - Integer.parseInt(idxStr2);
+        });
+        for (File sqlFile : sqlFiles) {
+            String sqlStatement = FileUtils.readFileToString(sqlFile, "UTF-8").trim();
+            int semicolonIndex = sqlStatement.lastIndexOf(";");
+            String sql = semicolonIndex != sqlStatement.length() - 1 ? sqlStatement.substring(0, semicolonIndex)
+                    : sqlStatement;
+            String metricsStr = sqlStatement.substring(semicolonIndex + 1);
+            ITQueryMetrics metrics = convertFromJson(metricsStr);
+            ret.add(Triple.create(sqlFile.getCanonicalPath(), sql + '\n', metrics));
+        }
+        return ret;
+    }
+
+    private static ITQueryMetrics convertFromJson(String metricsStr) throws IOException{
+         final ObjectMapper objectMapper = new ObjectMapper()
+                .configure(DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY, true);
+         ITQueryMetrics metrics = objectMapper.readValue(metricsStr, ITQueryMetrics.class);
+         return metrics;
+    }
+
     private static boolean compareResults(List<Row> expectedResult, List<Row> actualResult, CompareLevel compareLevel) {
         boolean good = true;
         if (compareLevel == CompareLevel.SAME_ORDER) {
@@ -401,7 +518,7 @@ public class NExecAndComp {
         }).collect(Collectors.toList());
     }
 
-    public static Dataset<Row> queryFromCube(String prj, String sqlText) {
+    public static Pair<Dataset<Row>, ITQueryMetrics> queryFromCube(String prj, String sqlText) {
         sqlText = QueryUtil.massageSql(sqlText, prj, 0, 0, "DEFAULT");
         return sql(prj, sqlText, null);
     }
@@ -414,21 +531,21 @@ public class NExecAndComp {
         return r;
     }
 
-    public static Dataset<Row> sql(String prj, String sqlText) {
+    public static Pair<Dataset<Row>, ITQueryMetrics> sql(String prj, String sqlText) {
         return sql(prj, sqlText, null);
     }
 
-    public static Dataset<Row> sql(String prj, String sqlText, List<String> parameters) {
+    public static Pair<Dataset<Row>, ITQueryMetrics> sql(String prj, String sqlText, List<String> parameters) {
         if (sqlText == null)
             throw new RuntimeException("Sorry your SQL is null...");
 
         try {
             logger.trace("Try to query from cube....");
             long startTs = System.currentTimeMillis();
-            Dataset<Row> dataset = queryCubeAndSkipCompute(prj, sqlText, parameters);
+            Pair<Dataset<Row>, ITQueryMetrics> pair = queryCubeAndSkipCompute(prj, sqlText, parameters);
             logger.trace("Cool! This sql hits cube...");
             logger.trace("Duration(ms): {}", (System.currentTimeMillis() - startTs));
-            return dataset;
+            return pair;
         } catch (Throwable e) {
             logger.error("There is no cube can be used for query [{}]", sqlText);
             logger.error("Reasons:", e);
@@ -436,26 +553,27 @@ public class NExecAndComp {
         }
     }
 
-    static Dataset<Row> queryCubeAndSkipCompute(String prj, String sql, List<String> parameters) throws Exception {
+    static Pair<Dataset<Row>, ITQueryMetrics> queryCubeAndSkipCompute(String prj, String sql, List<String> parameters) throws Exception {
         KylinSparkEnv.skipCompute();
-        Dataset<Row> df = queryCube(prj, sql, parameters);
-        return df;
+        Pair<Dataset<Row>, ITQueryMetrics> pair = queryCube(prj, sql, parameters);
+        return pair;
     }
 
-    static Dataset<Row> queryCubeAndSkipCompute(String prj, String sql) throws Exception {
+    static Pair<Dataset<Row>, ITQueryMetrics> queryCubeAndSkipCompute(String prj, String sql) throws Exception {
         KylinSparkEnv.skipCompute();
-        Dataset<Row> df = queryCube(prj, sql, null);
-        return df;
+        Pair<Dataset<Row>, ITQueryMetrics> pair = queryCube(prj, sql, null);
+        return pair;
     }
 
-    public static Dataset<Row> queryCube(String prj, String sql) throws SQLException {
+    public static Pair<Dataset<Row>, ITQueryMetrics> queryCube(String prj, String sql) throws SQLException {
         return queryCube(prj, sql, null);
     }
 
-    public static Dataset<Row> queryCube(String prj, String sql, List<String> parameters) throws SQLException {
+    public static Pair<Dataset<Row>, ITQueryMetrics> queryCube(String prj, String sql, List<String> parameters) throws SQLException {
         Connection conn = null;
         PreparedStatement stmt = null;
         ResultSet rs = null;
+        ITQueryMetrics metrics = null;
         try {
             conn = QueryConnection.getConnection(prj);
             stmt = conn.prepareStatement(sql);
@@ -463,13 +581,116 @@ public class NExecAndComp {
                 stmt.setString(i, parameters.get(i - 1).trim());
             }
             rs = stmt.executeQuery();
+            metrics = collectQueryMetrics(prj, rs);
         } finally {
             DBUtils.closeQuietly(rs);
             DBUtils.closeQuietly(stmt);
             DBUtils.closeQuietly(conn);
             //KylinSparkEnv.cleanCompute();
         }
-        return (Dataset<Row>) QueryContextFacade.current().getDataset();
+        return new Pair<>((Dataset<Row>) QueryContextFacade.current().getDataset(), metrics);
+    }
+
+    private static ITQueryMetrics collectQueryMetrics(String project, ResultSet resultSet) throws SQLException{
+        Pair<List<List<String>>, List<SelectedColumnMeta>> r = createResponseFromResultSet(resultSet);
+        SQLResponse response = buildSqlResponse(project, false, r.getFirst(), r.getSecond());
+        long scanRowCount = response.getTotalScanCount();
+        long scanFiles = response.getTotalScanFiles();
+        long scanBytes = response.getTotalScanBytes();
+        long hitCuboid = 0;
+        scanRowCount = 0;
+        scanFiles = 0;
+        scanBytes = 0;
+        try {
+            hitCuboid = OLAPContext.getThreadLocalContexts().iterator().next().storageContext.getCuboid().getId();
+        } catch (NullPointerException e) {
+            //e.printStackTrace();
+            logger.error("Query not hit cuboid!");
+        }
+        return new ITQueryMetrics(scanRowCount, scanBytes, scanFiles, hitCuboid);
+    }
+
+    private static Pair<List<List<String>>, List<SelectedColumnMeta>> createResponseFromResultSet(ResultSet resultSet) throws SQLException{
+        List<List<String>> results = Lists.newArrayList();
+        List<SelectedColumnMeta> columnMetas = Lists.newArrayList();
+
+        ResultSetMetaData metaData = resultSet.getMetaData();
+        int columnCount = metaData.getColumnCount();
+
+        // Fill in selected column meta
+        for (int i = 1; i <= columnCount; ++i) {
+            columnMetas.add(new SelectedColumnMeta(metaData.isAutoIncrement(i), metaData.isCaseSensitive(i),
+                    metaData.isSearchable(i), metaData.isCurrency(i), metaData.isNullable(i), metaData.isSigned(i),
+                    metaData.getColumnDisplaySize(i), metaData.getColumnLabel(i), metaData.getColumnName(i),
+                    metaData.getSchemaName(i), metaData.getCatalogName(i), metaData.getTableName(i),
+                    metaData.getPrecision(i), metaData.getScale(i), metaData.getColumnType(i),
+                    metaData.getColumnTypeName(i), metaData.isReadOnly(i), metaData.isWritable(i),
+                    metaData.isDefinitelyWritable(i)));
+        }
+
+        // fill in results
+        while (resultSet.next()) {
+            List<String> oneRow = Lists.newArrayListWithCapacity(columnCount);
+            for (int i = 0; i < columnCount; i++) {
+                oneRow.add((resultSet.getString(i + 1)));
+            }
+
+            results.add(oneRow);
+        }
+
+        return new Pair<>(results, columnMetas);
+    }
+
+    private static SQLResponse buildSqlResponse(String projectName, Boolean isPushDown, List<List<String>> results,
+                                         List<SelectedColumnMeta> columnMetas) {
+        return buildSqlResponse(projectName, isPushDown, results, columnMetas, false, null);
+    }
+
+    private static SQLResponse buildSqlResponse(String projectName, Boolean isPushDown, List<List<String>> results,
+                                         List<SelectedColumnMeta> columnMetas, boolean isException, String exceptionMessage) {
+
+        boolean isPartialResult = false;
+
+        List<String> realizations = Lists.newLinkedList();
+        StringBuilder cubeSb = new StringBuilder();
+        StringBuilder logSb = new StringBuilder("Processed rows for each storageContext: ");
+        QueryContext queryContext = QueryContextFacade.current();
+        if (OLAPContext.getThreadLocalContexts() != null) { // contexts can be null in case of 'explain plan for'
+            for (OLAPContext ctx : OLAPContext.getThreadLocalContexts()) {
+                String realizationName = "NULL";
+                int realizationType = -1;
+                if (ctx.realization != null) {
+                    isPartialResult |= ctx.storageContext.isPartialResultReturned();
+                    if (cubeSb.length() > 0) {
+                        cubeSb.append(",");
+                    }
+                    cubeSb.append(ctx.realization.getCanonicalName());
+                    logSb.append(ctx.storageContext.getProcessedRowCount()).append(" ");
+
+                    realizationName = ctx.realization.getName();
+                    realizationType = ctx.realization.getStorageType();
+
+                    realizations.add(realizationName);
+                }
+                queryContext.setContextRealization(ctx.id, realizationName, realizationType);
+            }
+        }
+        logger.info(logSb.toString());
+
+        SQLResponse response = new SQLResponse(columnMetas, results, cubeSb.toString(), 0, isException,
+                exceptionMessage, isPartialResult, isPushDown);
+        response.setTotalScanCount(queryContext.getScannedRows());
+        response.setTotalScanFiles((queryContext.getScanFiles() < 0) ? -1 :
+                queryContext.getScanFiles());
+        response.setMetadataTime((queryContext.getMedataTime() < 0) ? -1 :
+                queryContext.getMedataTime());
+        response.setTotalSparkScanTime((queryContext.getScanTime() < 0) ? -1 :
+                queryContext.getScanTime());
+        response.setTotalScanBytes((queryContext.getScannedBytes() < 0) ?
+                (queryContext.getSourceScanBytes() < 1 ? -1 : queryContext.getSourceScanBytes()) : queryContext.getScannedBytes());
+        response.setCubeSegmentStatisticsList(queryContext.getCubeSegmentStatisticsResultList());
+        response.setSparkPool(queryContext.getSparkPool());
+        return response;
     }
 
     private static String getCompareSql(String originSqlPath) {
@@ -538,4 +759,56 @@ public class NExecAndComp {
 
         return ret;
     }
+
+    static class ITQueryMetrics {
+        private long scanRowCount;
+        private long scanBytes;
+        private long scanFiles;
+        private long cuboidId;
+
+        public ITQueryMetrics() {}
+
+        public ITQueryMetrics(long scanRowCount, long scanBytes, long scanFiles, long cuboidId) {
+            this.scanRowCount = scanRowCount;
+            this.scanBytes = scanBytes;
+            this.scanFiles = scanFiles;
+            this.cuboidId = cuboidId;
+        }
+
+        public long getScanRowCount() {
+            return scanRowCount;
+        }
+
+        public void setScanRowCount(long scanRowCount) {
+            this.scanRowCount = scanRowCount;
+        }
+
+        public long getScanBytes() {
+            return scanBytes;
+        }
+
+        public void setScanBytes(long scanBytes) {
+            this.scanBytes = scanBytes;
+        }
+
+        public long getScanFiles() {
+            return scanFiles;
+        }
+
+        public void setScanFiles(long scanFiles) {
+            this.scanFiles = scanFiles;
+        }
+
+        public long getCuboidId() {
+            return cuboidId;
+        }
+
+        public void setCuboidId(long cuboidId) {
+            this.cuboidId = cuboidId;
+        }
+
+        public boolean equals(ITQueryMetrics metrics) {
+            return this.cuboidId == metrics.getCuboidId();
+        }
+    }
 }