From ca45e25642b0176a534f496355283a93c1148341 Mon Sep 17 00:00:00 2001 From: Apoorve Dave Date: Mon, 22 Mar 2021 14:53:24 -0700 Subject: [PATCH] updated plans after removing unneeded indexes --- .../approved-plans-v1_4/q0/explain.txt | 2 +- .../approved-plans-v1_4/q0/simplified.txt | 2 +- .../approved-plans-v1_4/q1/explain.txt | 2 +- .../approved-plans-v1_4/q1/simplified.txt | 2 +- .../approved-plans-v1_4/q11/explain.txt | 4 +- .../approved-plans-v1_4/q11/simplified.txt | 4 +- .../approved-plans-v1_4/q13/explain.txt | 2 +- .../approved-plans-v1_4/q13/simplified.txt | 2 +- .../approved-plans-v1_4/q14a/explain.txt | 40 ++++++------ .../approved-plans-v1_4/q14a/simplified.txt | 20 +++--- .../approved-plans-v1_4/q14b/explain.txt | 62 +++++++++---------- .../approved-plans-v1_4/q14b/simplified.txt | 14 ++--- .../approved-plans-v1_4/q18/explain.txt | 2 +- .../approved-plans-v1_4/q18/simplified.txt | 2 +- .../approved-plans-v1_4/q23a/explain.txt | 12 ++-- .../approved-plans-v1_4/q23a/simplified.txt | 4 +- .../approved-plans-v1_4/q23b/explain.txt | 6 +- .../approved-plans-v1_4/q23b/simplified.txt | 2 +- .../approved-plans-v1_4/q26/explain.txt | 6 +- .../approved-plans-v1_4/q26/simplified.txt | 2 +- .../approved-plans-v1_4/q27/explain.txt | 6 +- .../approved-plans-v1_4/q27/simplified.txt | 2 +- .../approved-plans-v1_4/q29/explain.txt | 18 +++--- .../approved-plans-v1_4/q29/simplified.txt | 2 +- .../approved-plans-v1_4/q30/explain.txt | 2 +- .../approved-plans-v1_4/q30/simplified.txt | 2 +- .../approved-plans-v1_4/q36/explain.txt | 2 +- .../approved-plans-v1_4/q36/simplified.txt | 2 +- .../approved-plans-v1_4/q4/explain.txt | 4 +- .../approved-plans-v1_4/q4/simplified.txt | 4 +- .../approved-plans-v1_4/q48/explain.txt | 2 +- .../approved-plans-v1_4/q48/simplified.txt | 2 +- .../approved-plans-v1_4/q50/explain.txt | 10 +-- .../approved-plans-v1_4/q50/simplified.txt | 2 +- .../approved-plans-v1_4/q64/explain.txt | 10 +-- .../approved-plans-v1_4/q64/simplified.txt | 6 +- .../approved-plans-v1_4/q7/explain.txt | 6 +- .../approved-plans-v1_4/q7/simplified.txt | 2 +- .../approved-plans-v1_4/q74/explain.txt | 4 +- .../approved-plans-v1_4/q74/simplified.txt | 4 +- .../approved-plans-v1_4/q75/explain.txt | 20 +++--- .../approved-plans-v1_4/q75/simplified.txt | 4 +- .../approved-plans-v1_4/q78/explain.txt | 12 ++-- .../approved-plans-v1_4/q78/simplified.txt | 2 +- .../approved-plans-v1_4/q81/explain.txt | 2 +- .../approved-plans-v1_4/q81/simplified.txt | 2 +- .../approved-plans-v1_4/q85/explain.txt | 2 +- .../approved-plans-v1_4/q85/simplified.txt | 2 +- .../goldstandard/TPCDS_Hyperspace.scala | 2 - 49 files changed, 165 insertions(+), 167 deletions(-) diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q0/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q0/explain.txt index 38b3528e..55f9fea7 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q0/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q0/explain.txt @@ -4,7 +4,7 @@ CollectLimit 100 +- *(3) SortMergeJoin [d_date_sk#3], [ss_sold_date_sk#4], Inner :- *(1) Project [d_date_sk#3, d_year#1] : +- *(1) Filter isnotnull(d_date_sk#3) - : +- *(1) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#3,d_year#1] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#3,d_year#1] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 +- *(2) Project [ss_sold_date_sk#4, ss_customer_sk#2] +- *(2) Filter isnotnull(ss_sold_date_sk#4) +- *(2) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#4,ss_customer_sk#2] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 \ No newline at end of file diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q0/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q0/simplified.txt index c22f87d3..071a1b3b 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q0/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q0/simplified.txt @@ -6,7 +6,7 @@ CollectLimit WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Project [ss_customer_sk,ss_sold_date_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q1/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q1/explain.txt index 632ac7a8..0fd21533 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q1/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q1/explain.txt @@ -25,7 +25,7 @@ TakeOrderedAndProject(limit=100, orderBy=[c_customer_id#1 ASC NULLS FIRST], outp : : : +- Exchange hashpartitioning(cast(d_date_sk#13 as bigint), 5) : : : +- *(3) Project [d_date_sk#13] : : : +- *(3) Filter ((isnotnull(d_year#14) && (d_year#14 = 2000)) && isnotnull(d_date_sk#13)) - : : : +- *(3) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#13,d_year#14] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct + : : : +- *(3) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#13,d_year#14] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct : : +- *(15) Sort [ctr_store_sk#4#6 ASC NULLS FIRST], false, 0 : : +- Exchange hashpartitioning(ctr_store_sk#4#6, 5) : : +- *(14) Filter isnotnull((CAST(avg(ctr_total_return) AS DECIMAL(21,6)) * CAST(1.2 AS DECIMAL(21,6)))#8) diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q1/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q1/simplified.txt index 56ea0193..64be6b73 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q1/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q1/simplified.txt @@ -45,7 +45,7 @@ TakeOrderedAndProject [c_customer_id] WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [ctr_store_skL] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q11/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q11/explain.txt index d2b1a15d..745aa972 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q11/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q11/explain.txt @@ -29,7 +29,7 @@ TakeOrderedAndProject(limit=100, orderBy=[customer_preferred_cust_flag#1 ASC NUL : : : : +- Exchange hashpartitioning(d_date_sk#21, 5) : : : : +- *(5) Project [d_date_sk#21, d_year#13] : : : : +- *(5) Filter ((isnotnull(d_year#13) && (d_year#13 = 2001)) && isnotnull(d_date_sk#21)) - : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#21,d_year#13] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct + : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#21,d_year#13] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct : : : +- LocalTableScan , [customer_id#24, year_total#25] : : +- *(18) Sort [customer_id#9 ASC NULLS FIRST], false, 0 : : +- Exchange hashpartitioning(customer_id#9, 5) @@ -45,7 +45,7 @@ TakeOrderedAndProject(limit=100, orderBy=[customer_preferred_cust_flag#1 ASC NUL : : : +- Exchange hashpartitioning(d_date_sk#21, 5) : : : +- *(14) Project [d_date_sk#21, d_year#13] : : : +- *(14) Filter ((isnotnull(d_year#13) && (d_year#13 = 2002)) && isnotnull(d_date_sk#21)) - : : : +- *(14) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#21,d_year#13] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct + : : : +- *(14) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#21,d_year#13] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct : : +- LocalTableScan , [customer_id#24, customer_preferred_cust_flag#26, year_total#25] : +- *(28) Sort [customer_id#8 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(customer_id#8, 5) diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q11/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q11/simplified.txt index c7e570d3..782d0258 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q11/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q11/simplified.txt @@ -51,7 +51,7 @@ TakeOrderedAndProject [customer_preferred_cust_flag] WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] LocalTableScan [customer_id,year_total] [customer_id,year_total] InputAdapter WholeStageCodegen @@ -80,7 +80,7 @@ TakeOrderedAndProject [customer_preferred_cust_flag] WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] LocalTableScan [customer_id,customer_preferred_cust_flag,year_total] [customer_id,customer_preferred_cust_flag,year_total] InputAdapter WholeStageCodegen diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q13/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q13/explain.txt index f7b497e6..9795660e 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q13/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q13/explain.txt @@ -35,7 +35,7 @@ : : +- Exchange hashpartitioning(d_date_sk#13, 5) : : +- *(9) Project [d_date_sk#13] : : +- *(9) Filter ((isnotnull(d_year#21) && (d_year#21 = 2001)) && isnotnull(d_date_sk#13)) - : : +- *(9) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#13,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct + : : +- *(9) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#13,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct : +- *(14) Sort [cd_demo_sk#11 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(cd_demo_sk#11, 5) : +- *(13) Project [cd_demo_sk#11, cd_marital_status#6, cd_education_status#7] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q13/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q13/simplified.txt index 76b12cf2..39fc9ac3 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q13/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q13/simplified.txt @@ -65,7 +65,7 @@ WholeStageCodegen WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [cd_demo_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14a/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14a/explain.txt index adb21929..b3f7c037 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14a/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14a/explain.txt @@ -6,8 +6,8 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 +- *(229) Expand [List(sales#8, number_sales#9, channel#10, i_brand_id#11, i_class_id#12, i_category_id#13, 0), List(sales#8, number_sales#9, channel#10, i_brand_id#11, i_class_id#12, null, 1), List(sales#8, number_sales#9, channel#10, i_brand_id#11, null, null, 3), List(sales#8, number_sales#9, channel#10, null, null, null, 7), List(sales#8, number_sales#9, null, null, null, null, 15)], [sales#8, number_sales#9, channel#1, i_brand_id#2, i_class_id#3, i_category_id#4, spark_grouping_id#7] +- Union :- *(76) Project [sales#8, number_sales#9, channel#10, i_brand_id#11, i_class_id#12, i_category_id#13] - : +- *(76) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#14 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#15 as decimal(12,2)))), DecimalType(18,2)))#16) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#14 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#15 as decimal(12,2)))), DecimalType(18,2)))#16 as decimal(32,6)) > cast(Subquery subquery2858 as decimal(32,6)))) - : : +- Subquery subquery2858 + : +- *(76) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#14 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#15 as decimal(12,2)))), DecimalType(18,2)))#16) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#14 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#15 as decimal(12,2)))), DecimalType(18,2)))#16 as decimal(32,6)) > cast(Subquery subquery2807 as decimal(32,6)))) + : : +- Subquery subquery2807 : : +- *(11) HashAggregate(keys=[], functions=[avg(CheckOverflow((promote_precision(cast(cast(quantity#17 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#18 as decimal(12,2)))), DecimalType(18,2)))]) : : +- Exchange SinglePartition : : +- *(10) HashAggregate(keys=[], functions=[partial_avg(CheckOverflow((promote_precision(cast(cast(quantity#17 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#18 as decimal(12,2)))), DecimalType(18,2)))]) @@ -19,7 +19,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#19,ss_quantity#14,ss_list_price#15] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : +- *(2) Project [d_date_sk#20] : : : +- *(2) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : : : +- *(2) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : +- *(2) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : :- *(6) Project [cs_quantity#22 AS quantity#23, cs_list_price#24 AS list_price#25] : : : +- *(6) SortMergeJoin [cs_sold_date_sk#26], [d_date_sk#20], Inner : : : :- *(4) Project [cs_sold_date_sk#26, cs_quantity#22, cs_list_price#24] @@ -27,7 +27,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : : +- *(4) FileScan Hyperspace(Type: CI, Name: JoinIndex26-index-6-cs_sold_date_sk-26, LogVersion: 0) default.catalog_sales[cs_sold_date_sk#26,cs_quantity#22,cs_list_price#24] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cs_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : +- *(5) Project [d_date_sk#20] : : : +- *(5) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : +- *(5) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(9) Project [ws_quantity#27 AS quantity#28, ws_list_price#29 AS list_price#30] : : +- *(9) SortMergeJoin [ws_sold_date_sk#31], [d_date_sk#20], Inner : : :- *(7) Project [ws_sold_date_sk#31, ws_quantity#27, ws_list_price#29] @@ -35,7 +35,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : +- *(7) FileScan Hyperspace(Type: CI, Name: JoinIndex37-index-9-ws_sold_date_sk-21, LogVersion: 0) default.web_sales[ws_sold_date_sk#31,ws_quantity#27,ws_list_price#29] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ws_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(8) Project [d_date_sk#20] : : +- *(8) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : : +- *(8) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : +- *(8) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : +- *(76) HashAggregate(keys=[i_brand_id#11, i_class_id#12, i_category_id#13], functions=[sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#14 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#15 as decimal(12,2)))), DecimalType(18,2))), count(1)]) : +- Exchange hashpartitioning(i_brand_id#11, i_class_id#12, i_category_id#13, 5) : +- *(75) HashAggregate(keys=[i_brand_id#11, i_class_id#12, i_category_id#13], functions=[partial_sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#14 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#15 as decimal(12,2)))), DecimalType(18,2))), partial_count(1)]) @@ -58,8 +58,8 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : :- *(4) Sort [i_brand_id#11 ASC NULLS FIRST, i_class_id#12 ASC NULLS FIRST, i_category_id#13 ASC NULLS FIRST], false, 0 : : : : +- Exchange hashpartitioning(i_brand_id#11, i_class_id#12, i_category_id#13, 5) : : : : +- *(3) Project [i_item_sk#33, i_brand_id#11, i_class_id#12, i_category_id#13] - : : : : +- *(3) Filter ((isnotnull(i_brand_id#11) && isnotnull(i_category_id#13)) && isnotnull(i_class_id#12)) - : : : : +- *(3) FileScan parquet default.item[i_item_sk#33,i_brand_id#11,i_class_id#12,i_category_id#13] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/item], PartitionFilters: [], PushedFilters: [IsNotNull(i_brand_id), IsNotNull(i_category_id), IsNotNull(i_class_id)], ReadSchema: struct + : : : : +- *(3) Filter ((isnotnull(i_category_id#13) && isnotnull(i_brand_id#11)) && isnotnull(i_class_id#12)) + : : : : +- *(3) FileScan parquet default.item[i_item_sk#33,i_brand_id#11,i_class_id#12,i_category_id#13] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/item], PartitionFilters: [], PushedFilters: [IsNotNull(i_category_id), IsNotNull(i_brand_id), IsNotNull(i_class_id)], ReadSchema: struct : : : +- *(33) Sort [brand_id#35 ASC NULLS FIRST, class_id#36 ASC NULLS FIRST, category_id#37 ASC NULLS FIRST], false, 0 : : : +- *(33) HashAggregate(keys=[brand_id#35, class_id#36, category_id#37], functions=[]) : : : +- Exchange hashpartitioning(brand_id#35, class_id#36, category_id#37, 5) @@ -83,13 +83,13 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : : : : : +- *(5) Filter (isnotnull(ss_item_sk#32) && isnotnull(ss_sold_date_sk#19)) : : : : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: JoinIndex13-index-3-ss_item_sk-16, LogVersion: 0) default.store_sales[ss_sold_date_sk#19,ss_item_sk#32] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_item_sk), IsNotNull(ss_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : : : : +- *(6) Project [i_item_sk#33, i_brand_id#11, i_class_id#12, i_category_id#13] - : : : : : : +- *(6) Filter (((isnotnull(i_item_sk#33) && isnotnull(i_class_id#12)) && isnotnull(i_category_id#13)) && isnotnull(i_brand_id#11)) - : : : : : : +- *(6) FileScan Hyperspace(Type: CI, Name: JoinIndex08-index-2-i_item_sk-17, LogVersion: 0) default.item[i_item_sk#33,i_brand_id#11,i_class_id#12,i_category_id#13] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(i_item_sk), IsNotNull(i_class_id), IsNotNull(i_category_id), IsNotNull(i_brand_id)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : : : : +- *(6) Filter (((isnotnull(i_item_sk#33) && isnotnull(i_category_id#13)) && isnotnull(i_class_id#12)) && isnotnull(i_brand_id#11)) + : : : : : : +- *(6) FileScan Hyperspace(Type: CI, Name: JoinIndex08-index-2-i_item_sk-17, LogVersion: 0) default.item[i_item_sk#33,i_brand_id#11,i_class_id#12,i_category_id#13] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(i_item_sk), IsNotNull(i_category_id), IsNotNull(i_class_id), IsNotNull(i_brand_id)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : : : +- *(10) Sort [d_date_sk#20 ASC NULLS FIRST], false, 0 : : : : : +- Exchange hashpartitioning(d_date_sk#20, 5) : : : : : +- *(9) Project [d_date_sk#20] : : : : : +- *(9) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : : : : : +- *(9) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct + : : : : : +- *(9) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct : : : : +- *(20) Sort [coalesce(i_brand_id#11, 0) ASC NULLS FIRST, coalesce(i_class_id#12, 0) ASC NULLS FIRST, coalesce(i_category_id#13, 0) ASC NULLS FIRST], false, 0 : : : : +- Exchange hashpartitioning(coalesce(i_brand_id#11, 0), coalesce(i_class_id#12, 0), coalesce(i_category_id#13, 0), 5) : : : : +- *(19) Project [i_brand_id#11, i_class_id#12, i_category_id#13] @@ -136,8 +136,8 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : +- *(73) Filter ((((isnotnull(d_year#21) && isnotnull(d_moy#40)) && (d_year#21 = 2001)) && (d_moy#40 = 11)) && isnotnull(d_date_sk#20)) : +- *(73) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21,d_moy#40] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), IsNotNull(d_moy), EqualTo(d_year,2001), EqualTo(d_moy,11), IsNotNull(d_date_sk)], ReadSchema: struct :- *(152) Project [sales#41, number_sales#42, channel#43, i_brand_id#11, i_class_id#12, i_category_id#13] - : +- *(152) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(cs_quantity#22 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(cs_list_price#24 as decimal(12,2)))), DecimalType(18,2)))#44) && (cast(sum(CheckOverflow((promote_precision(cast(cast(cs_quantity#22 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(cs_list_price#24 as decimal(12,2)))), DecimalType(18,2)))#44 as decimal(32,6)) > cast(Subquery subquery2863 as decimal(32,6)))) - : : +- Subquery subquery2863 + : +- *(152) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(cs_quantity#22 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(cs_list_price#24 as decimal(12,2)))), DecimalType(18,2)))#44) && (cast(sum(CheckOverflow((promote_precision(cast(cast(cs_quantity#22 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(cs_list_price#24 as decimal(12,2)))), DecimalType(18,2)))#44 as decimal(32,6)) > cast(Subquery subquery2812 as decimal(32,6)))) + : : +- Subquery subquery2812 : : +- *(11) HashAggregate(keys=[], functions=[avg(CheckOverflow((promote_precision(cast(cast(quantity#17 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#18 as decimal(12,2)))), DecimalType(18,2)))]) : : +- Exchange SinglePartition : : +- *(10) HashAggregate(keys=[], functions=[partial_avg(CheckOverflow((promote_precision(cast(cast(quantity#17 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#18 as decimal(12,2)))), DecimalType(18,2)))]) @@ -149,7 +149,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#19,ss_quantity#14,ss_list_price#15] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : +- *(2) Project [d_date_sk#20] : : : +- *(2) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : : : +- *(2) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : +- *(2) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : :- *(6) Project [cs_quantity#22 AS quantity#23, cs_list_price#24 AS list_price#25] : : : +- *(6) SortMergeJoin [cs_sold_date_sk#26], [d_date_sk#20], Inner : : : :- *(4) Project [cs_sold_date_sk#26, cs_quantity#22, cs_list_price#24] @@ -157,7 +157,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : : +- *(4) FileScan Hyperspace(Type: CI, Name: JoinIndex26-index-6-cs_sold_date_sk-26, LogVersion: 0) default.catalog_sales[cs_sold_date_sk#26,cs_quantity#22,cs_list_price#24] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cs_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : +- *(5) Project [d_date_sk#20] : : : +- *(5) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : +- *(5) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(9) Project [ws_quantity#27 AS quantity#28, ws_list_price#29 AS list_price#30] : : +- *(9) SortMergeJoin [ws_sold_date_sk#31], [d_date_sk#20], Inner : : :- *(7) Project [ws_sold_date_sk#31, ws_quantity#27, ws_list_price#29] @@ -165,7 +165,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : +- *(7) FileScan Hyperspace(Type: CI, Name: JoinIndex37-index-9-ws_sold_date_sk-21, LogVersion: 0) default.web_sales[ws_sold_date_sk#31,ws_quantity#27,ws_list_price#29] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ws_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(8) Project [d_date_sk#20] : : +- *(8) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : : +- *(8) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : +- *(8) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : +- *(152) HashAggregate(keys=[i_brand_id#11, i_class_id#12, i_category_id#13], functions=[sum(CheckOverflow((promote_precision(cast(cast(cs_quantity#22 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(cs_list_price#24 as decimal(12,2)))), DecimalType(18,2))), count(1)]) : +- Exchange hashpartitioning(i_brand_id#11, i_class_id#12, i_category_id#13, 5) : +- *(151) HashAggregate(keys=[i_brand_id#11, i_class_id#12, i_category_id#13], functions=[partial_sum(CheckOverflow((promote_precision(cast(cast(cs_quantity#22 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(cs_list_price#24 as decimal(12,2)))), DecimalType(18,2))), partial_count(1)]) @@ -191,8 +191,8 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : +- *(150) Sort [d_date_sk#20 ASC NULLS FIRST], false, 0 : +- ReusedExchange [d_date_sk#20], Exchange hashpartitioning(d_date_sk#20, 5) +- *(228) Project [sales#45, number_sales#46, channel#47, i_brand_id#11, i_class_id#12, i_category_id#13] - +- *(228) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ws_quantity#27 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ws_list_price#29 as decimal(12,2)))), DecimalType(18,2)))#48) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ws_quantity#27 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ws_list_price#29 as decimal(12,2)))), DecimalType(18,2)))#48 as decimal(32,6)) > cast(Subquery subquery2868 as decimal(32,6)))) - : +- Subquery subquery2868 + +- *(228) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ws_quantity#27 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ws_list_price#29 as decimal(12,2)))), DecimalType(18,2)))#48) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ws_quantity#27 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ws_list_price#29 as decimal(12,2)))), DecimalType(18,2)))#48 as decimal(32,6)) > cast(Subquery subquery2817 as decimal(32,6)))) + : +- Subquery subquery2817 : +- *(11) HashAggregate(keys=[], functions=[avg(CheckOverflow((promote_precision(cast(cast(quantity#17 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#18 as decimal(12,2)))), DecimalType(18,2)))]) : +- Exchange SinglePartition : +- *(10) HashAggregate(keys=[], functions=[partial_avg(CheckOverflow((promote_precision(cast(cast(quantity#17 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#18 as decimal(12,2)))), DecimalType(18,2)))]) @@ -204,7 +204,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#19,ss_quantity#14,ss_list_price#15] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(2) Project [d_date_sk#20] : : +- *(2) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : : +- *(2) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : +- *(2) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : :- *(6) Project [cs_quantity#22 AS quantity#23, cs_list_price#24 AS list_price#25] : : +- *(6) SortMergeJoin [cs_sold_date_sk#26], [d_date_sk#20], Inner : : :- *(4) Project [cs_sold_date_sk#26, cs_quantity#22, cs_list_price#24] @@ -212,7 +212,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : +- *(4) FileScan Hyperspace(Type: CI, Name: JoinIndex26-index-6-cs_sold_date_sk-26, LogVersion: 0) default.catalog_sales[cs_sold_date_sk#26,cs_quantity#22,cs_list_price#24] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cs_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(5) Project [d_date_sk#20] : : +- *(5) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : +- *(5) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : +- *(9) Project [ws_quantity#27 AS quantity#28, ws_list_price#29 AS list_price#30] : +- *(9) SortMergeJoin [ws_sold_date_sk#31], [d_date_sk#20], Inner : :- *(7) Project [ws_sold_date_sk#31, ws_quantity#27, ws_list_price#29] @@ -220,7 +220,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : +- *(7) FileScan Hyperspace(Type: CI, Name: JoinIndex37-index-9-ws_sold_date_sk-21, LogVersion: 0) default.web_sales[ws_sold_date_sk#31,ws_quantity#27,ws_list_price#29] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ws_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : +- *(8) Project [d_date_sk#20] : +- *(8) Filter (((isnotnull(d_year#21) && (d_year#21 >= 1999)) && (d_year#21 <= 2001)) && isnotnull(d_date_sk#20)) - : +- *(8) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : +- *(8) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#20,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 +- *(228) HashAggregate(keys=[i_brand_id#11, i_class_id#12, i_category_id#13], functions=[sum(CheckOverflow((promote_precision(cast(cast(ws_quantity#27 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ws_list_price#29 as decimal(12,2)))), DecimalType(18,2))), count(1)]) +- Exchange hashpartitioning(i_brand_id#11, i_class_id#12, i_category_id#13, 5) +- *(227) HashAggregate(keys=[i_brand_id#11, i_class_id#12, i_category_id#13], functions=[partial_sum(CheckOverflow((promote_precision(cast(cast(ws_quantity#27 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ws_list_price#29 as decimal(12,2)))), DecimalType(18,2))), partial_count(1)]) diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14a/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14a/simplified.txt index f5b5bc59..59ea4ce0 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14a/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14a/simplified.txt @@ -32,7 +32,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [cs_list_price,cs_quantity] SortMergeJoin [cs_sold_date_sk,d_date_sk] @@ -45,7 +45,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [ws_list_price,ws_quantity] SortMergeJoin [d_date_sk,ws_sold_date_sk] @@ -58,7 +58,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] HashAggregate [count,count(1),i_brand_id,i_category_id,i_class_id,sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price as decimal(12,2)))), DecimalType(18,2)))] [channel,count,count(1),number_sales,sales,sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price as decimal(12,2)))), DecimalType(18,2))),sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price as decimal(12,2)))), DecimalType(18,2)))] InputAdapter Exchange [i_brand_id,i_category_id,i_class_id] #2 @@ -155,7 +155,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Sort [i_brand_id,i_category_id,i_class_id] InputAdapter @@ -263,7 +263,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [cs_list_price,cs_quantity] SortMergeJoin [cs_sold_date_sk,d_date_sk] @@ -276,7 +276,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [ws_list_price,ws_quantity] SortMergeJoin [d_date_sk,ws_sold_date_sk] @@ -289,7 +289,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] HashAggregate [count,count(1),i_brand_id,i_category_id,i_class_id,sum,sum(CheckOverflow((promote_precision(cast(cast(cs_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(cs_list_price as decimal(12,2)))), DecimalType(18,2)))] [channel,count,count(1),number_sales,sales,sum,sum(CheckOverflow((promote_precision(cast(cast(cs_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(cs_list_price as decimal(12,2)))), DecimalType(18,2))),sum(CheckOverflow((promote_precision(cast(cast(cs_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(cs_list_price as decimal(12,2)))), DecimalType(18,2)))] InputAdapter Exchange [i_brand_id,i_category_id,i_class_id] #20 @@ -358,7 +358,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [cs_list_price,cs_quantity] SortMergeJoin [cs_sold_date_sk,d_date_sk] @@ -371,7 +371,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [ws_list_price,ws_quantity] SortMergeJoin [d_date_sk,ws_sold_date_sk] @@ -384,7 +384,7 @@ TakeOrderedAndProject [channel,i_brand_id,i_category_id,i_class_id,sum(number_sa WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] HashAggregate [count,count(1),i_brand_id,i_category_id,i_class_id,sum,sum(CheckOverflow((promote_precision(cast(cast(ws_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ws_list_price as decimal(12,2)))), DecimalType(18,2)))] [channel,count,count(1),number_sales,sales,sum,sum(CheckOverflow((promote_precision(cast(cast(ws_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ws_list_price as decimal(12,2)))), DecimalType(18,2))),sum(CheckOverflow((promote_precision(cast(cast(ws_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ws_list_price as decimal(12,2)))), DecimalType(18,2)))] InputAdapter Exchange [i_brand_id,i_category_id,i_class_id] #23 diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14b/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14b/explain.txt index 1063c95f..13996c89 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14b/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14b/explain.txt @@ -3,8 +3,8 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 +- *(153) SortMergeJoin [i_brand_id#2, i_class_id#3, i_category_id#4], [i_brand_id#8, i_class_id#9, i_category_id#10], Inner :- *(76) Sort [i_brand_id#2 ASC NULLS FIRST, i_class_id#3 ASC NULLS FIRST, i_category_id#4 ASC NULLS FIRST], false, 0 : +- *(76) Project [channel#1, i_brand_id#2, i_class_id#3, i_category_id#4, sales#5, number_sales#6] - : +- *(76) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2)))#15) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2)))#15 as decimal(32,6)) > cast(Subquery subquery3080 as decimal(32,6)))) - : : +- Subquery subquery3080 + : +- *(76) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2)))#15) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2)))#15 as decimal(32,6)) > cast(Subquery subquery3029 as decimal(32,6)))) + : : +- Subquery subquery3029 : : +- *(11) HashAggregate(keys=[], functions=[avg(CheckOverflow((promote_precision(cast(cast(quantity#16 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#17 as decimal(12,2)))), DecimalType(18,2)))]) : : +- Exchange SinglePartition : : +- *(10) HashAggregate(keys=[], functions=[partial_avg(CheckOverflow((promote_precision(cast(cast(quantity#16 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#17 as decimal(12,2)))), DecimalType(18,2)))]) @@ -16,7 +16,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#18,ss_quantity#13,ss_list_price#14] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : +- *(2) Project [d_date_sk#19] : : : +- *(2) Filter (((isnotnull(d_year#20) && (d_year#20 >= 1999)) && (d_year#20 <= 2001)) && isnotnull(d_date_sk#19)) - : : : +- *(2) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : +- *(2) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : :- *(6) Project [cs_quantity#21 AS quantity#22, cs_list_price#23 AS list_price#24] : : : +- *(6) SortMergeJoin [cs_sold_date_sk#25], [d_date_sk#19], Inner : : : :- *(4) Project [cs_sold_date_sk#25, cs_quantity#21, cs_list_price#23] @@ -24,7 +24,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : : +- *(4) FileScan Hyperspace(Type: CI, Name: JoinIndex26-index-6-cs_sold_date_sk-26, LogVersion: 0) default.catalog_sales[cs_sold_date_sk#25,cs_quantity#21,cs_list_price#23] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cs_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : +- *(5) Project [d_date_sk#19] : : : +- *(5) Filter (((isnotnull(d_year#20) && (d_year#20 >= 1999)) && (d_year#20 <= 2001)) && isnotnull(d_date_sk#19)) - : : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : +- *(5) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(9) Project [ws_quantity#26 AS quantity#27, ws_list_price#28 AS list_price#29] : : +- *(9) SortMergeJoin [ws_sold_date_sk#30], [d_date_sk#19], Inner : : :- *(7) Project [ws_sold_date_sk#30, ws_quantity#26, ws_list_price#28] @@ -32,7 +32,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : +- *(7) FileScan Hyperspace(Type: CI, Name: JoinIndex37-index-9-ws_sold_date_sk-21, LogVersion: 0) default.web_sales[ws_sold_date_sk#30,ws_quantity#26,ws_list_price#28] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ws_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(8) Project [d_date_sk#19] : : +- *(8) Filter (((isnotnull(d_year#20) && (d_year#20 >= 1999)) && (d_year#20 <= 2001)) && isnotnull(d_date_sk#19)) - : : +- *(8) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : +- *(8) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : +- *(76) HashAggregate(keys=[i_brand_id#2, i_class_id#3, i_category_id#4], functions=[sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2))), count(1)]) : +- Exchange hashpartitioning(i_brand_id#2, i_class_id#3, i_category_id#4, 5) : +- *(75) HashAggregate(keys=[i_brand_id#2, i_class_id#3, i_category_id#4], functions=[partial_sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2))), partial_count(1)]) @@ -55,8 +55,8 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : :- *(4) Sort [i_brand_id#2 ASC NULLS FIRST, i_class_id#3 ASC NULLS FIRST, i_category_id#4 ASC NULLS FIRST], false, 0 : : : : +- Exchange hashpartitioning(i_brand_id#2, i_class_id#3, i_category_id#4, 5) : : : : +- *(3) Project [i_item_sk#32, i_brand_id#2, i_class_id#3, i_category_id#4] - : : : : +- *(3) Filter ((isnotnull(i_brand_id#2) && isnotnull(i_category_id#4)) && isnotnull(i_class_id#3)) - : : : : +- *(3) FileScan parquet default.item[i_item_sk#32,i_brand_id#2,i_class_id#3,i_category_id#4] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/item], PartitionFilters: [], PushedFilters: [IsNotNull(i_brand_id), IsNotNull(i_category_id), IsNotNull(i_class_id)], ReadSchema: struct + : : : : +- *(3) Filter ((isnotnull(i_category_id#4) && isnotnull(i_brand_id#2)) && isnotnull(i_class_id#3)) + : : : : +- *(3) FileScan parquet default.item[i_item_sk#32,i_brand_id#2,i_class_id#3,i_category_id#4] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/item], PartitionFilters: [], PushedFilters: [IsNotNull(i_category_id), IsNotNull(i_brand_id), IsNotNull(i_class_id)], ReadSchema: struct : : : +- *(33) Sort [brand_id#34 ASC NULLS FIRST, class_id#35 ASC NULLS FIRST, category_id#36 ASC NULLS FIRST], false, 0 : : : +- *(33) HashAggregate(keys=[brand_id#34, class_id#35, category_id#36], functions=[]) : : : +- Exchange hashpartitioning(brand_id#34, class_id#35, category_id#36, 5) @@ -80,13 +80,13 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : : : : : +- *(5) Filter (isnotnull(ss_item_sk#31) && isnotnull(ss_sold_date_sk#18)) : : : : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: JoinIndex13-index-3-ss_item_sk-16, LogVersion: 0) default.store_sales[ss_sold_date_sk#18,ss_item_sk#31] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_item_sk), IsNotNull(ss_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : : : : +- *(6) Project [i_item_sk#32, i_brand_id#2, i_class_id#3, i_category_id#4] - : : : : : : +- *(6) Filter (((isnotnull(i_item_sk#32) && isnotnull(i_brand_id#2)) && isnotnull(i_category_id#4)) && isnotnull(i_class_id#3)) - : : : : : : +- *(6) FileScan Hyperspace(Type: CI, Name: JoinIndex08-index-2-i_item_sk-17, LogVersion: 0) default.item[i_item_sk#32,i_brand_id#2,i_class_id#3,i_category_id#4] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(i_item_sk), IsNotNull(i_brand_id), IsNotNull(i_category_id), IsNotNull(i_class_id)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : : : : +- *(6) Filter (((isnotnull(i_item_sk#32) && isnotnull(i_class_id#3)) && isnotnull(i_brand_id#2)) && isnotnull(i_category_id#4)) + : : : : : : +- *(6) FileScan Hyperspace(Type: CI, Name: JoinIndex08-index-2-i_item_sk-17, LogVersion: 0) default.item[i_item_sk#32,i_brand_id#2,i_class_id#3,i_category_id#4] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(i_item_sk), IsNotNull(i_class_id), IsNotNull(i_brand_id), IsNotNull(i_category_id)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : : : : +- *(10) Sort [d_date_sk#19 ASC NULLS FIRST], false, 0 : : : : : +- Exchange hashpartitioning(d_date_sk#19, 5) : : : : : +- *(9) Project [d_date_sk#19] : : : : : +- *(9) Filter (((isnotnull(d_year#20) && (d_year#20 >= 1999)) && (d_year#20 <= 2001)) && isnotnull(d_date_sk#19)) - : : : : : +- *(9) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct + : : : : : +- *(9) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct : : : : +- *(20) Sort [coalesce(i_brand_id#2, 0) ASC NULLS FIRST, coalesce(i_class_id#3, 0) ASC NULLS FIRST, coalesce(i_category_id#4, 0) ASC NULLS FIRST], false, 0 : : : : +- Exchange hashpartitioning(coalesce(i_brand_id#2, 0), coalesce(i_class_id#3, 0), coalesce(i_category_id#4, 0), 5) : : : : +- *(19) Project [i_brand_id#2, i_class_id#3, i_category_id#4] @@ -123,27 +123,27 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : :- *(37) Sort [i_item_sk#32 ASC NULLS FIRST], false, 0 : : : +- Exchange hashpartitioning(i_item_sk#32, 5) : : : +- *(36) Project [i_item_sk#32, i_brand_id#2, i_class_id#3, i_category_id#4] - : : : +- *(36) Filter (((isnotnull(i_item_sk#32) && isnotnull(i_category_id#4)) && isnotnull(i_class_id#3)) && isnotnull(i_brand_id#2)) - : : : +- *(36) FileScan Hyperspace(Type: CI, Name: JoinIndex08-index-2-i_item_sk-17, LogVersion: 0) default.item[i_item_sk#32,i_brand_id#2,i_class_id#3,i_category_id#4] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(i_item_sk), IsNotNull(i_category_id), IsNotNull(i_class_id), IsNotNull(i_brand_id)], ReadSchema: struct + : : : +- *(36) Filter (((isnotnull(i_item_sk#32) && isnotnull(i_category_id#4)) && isnotnull(i_brand_id#2)) && isnotnull(i_class_id#3)) + : : : +- *(36) FileScan Hyperspace(Type: CI, Name: JoinIndex08-index-2-i_item_sk-17, LogVersion: 0) default.item[i_item_sk#32,i_brand_id#2,i_class_id#3,i_category_id#4] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(i_item_sk), IsNotNull(i_category_id), IsNotNull(i_brand_id), IsNotNull(i_class_id)], ReadSchema: struct : : +- *(70) Sort [ss_item_sk#33 ASC NULLS FIRST], false, 0 : : +- ReusedExchange [ss_item_sk#33], Exchange hashpartitioning(ss_item_sk#33, 5) : +- *(74) Sort [d_date_sk#19 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(d_date_sk#19, 5) : +- *(73) Project [d_date_sk#19] - : +- *(73) Filter ((isnotnull(d_week_seq#39) && (d_week_seq#39 = Subquery subquery3079)) && isnotnull(d_date_sk#19)) - : : +- Subquery subquery3079 + : +- *(73) Filter ((isnotnull(d_week_seq#39) && (d_week_seq#39 = Subquery subquery3028)) && isnotnull(d_date_sk#19)) + : : +- Subquery subquery3028 : : +- *(1) Project [d_week_seq#39] - : : +- *(1) Filter (((((isnotnull(d_dom#40) && isnotnull(d_year#20)) && isnotnull(d_moy#41)) && (d_year#20 = 2000)) && (d_moy#41 = 12)) && (d_dom#40 = 11)) - : : +- *(1) FileScan parquet default.date_dim[d_week_seq#39,d_year#20,d_moy#41,d_dom#40] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/date_dim], PartitionFilters: [], PushedFilters: [IsNotNull(d_dom), IsNotNull(d_year), IsNotNull(d_moy), EqualTo(d_year,2000), EqualTo(d_moy,12), ..., ReadSchema: struct + : : +- *(1) Filter (((((isnotnull(d_moy#40) && isnotnull(d_dom#41)) && isnotnull(d_year#20)) && (d_year#20 = 2000)) && (d_moy#40 = 12)) && (d_dom#41 = 11)) + : : +- *(1) FileScan parquet default.date_dim[d_week_seq#39,d_year#20,d_moy#40,d_dom#41] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/date_dim], PartitionFilters: [], PushedFilters: [IsNotNull(d_moy), IsNotNull(d_dom), IsNotNull(d_year), EqualTo(d_year,2000), EqualTo(d_moy,12), ..., ReadSchema: struct : +- *(73) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#19,d_week_seq#39] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_week_seq), IsNotNull(d_date_sk)], ReadSchema: struct - : +- Subquery subquery3079 + : +- Subquery subquery3028 : +- *(1) Project [d_week_seq#39] - : +- *(1) Filter (((((isnotnull(d_dom#40) && isnotnull(d_year#20)) && isnotnull(d_moy#41)) && (d_year#20 = 2000)) && (d_moy#41 = 12)) && (d_dom#40 = 11)) - : +- *(1) FileScan parquet default.date_dim[d_week_seq#39,d_year#20,d_moy#41,d_dom#40] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/date_dim], PartitionFilters: [], PushedFilters: [IsNotNull(d_dom), IsNotNull(d_year), IsNotNull(d_moy), EqualTo(d_year,2000), EqualTo(d_moy,12), ..., ReadSchema: struct + : +- *(1) Filter (((((isnotnull(d_moy#40) && isnotnull(d_dom#41)) && isnotnull(d_year#20)) && (d_year#20 = 2000)) && (d_moy#40 = 12)) && (d_dom#41 = 11)) + : +- *(1) FileScan parquet default.date_dim[d_week_seq#39,d_year#20,d_moy#40,d_dom#41] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/date_dim], PartitionFilters: [], PushedFilters: [IsNotNull(d_moy), IsNotNull(d_dom), IsNotNull(d_year), EqualTo(d_year,2000), EqualTo(d_moy,12), ..., ReadSchema: struct +- *(152) Sort [i_brand_id#8 ASC NULLS FIRST, i_class_id#9 ASC NULLS FIRST, i_category_id#10 ASC NULLS FIRST], false, 0 +- *(152) Project [channel#7, i_brand_id#8, i_class_id#9, i_category_id#10, sales#11, number_sales#12] - +- *(152) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2)))#42) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2)))#42 as decimal(32,6)) > cast(Subquery subquery3086 as decimal(32,6)))) - : +- Subquery subquery3086 + +- *(152) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2)))#42) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2)))#42 as decimal(32,6)) > cast(Subquery subquery3035 as decimal(32,6)))) + : +- Subquery subquery3035 : +- *(11) HashAggregate(keys=[], functions=[avg(CheckOverflow((promote_precision(cast(cast(quantity#16 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#17 as decimal(12,2)))), DecimalType(18,2)))]) : +- Exchange SinglePartition : +- *(10) HashAggregate(keys=[], functions=[partial_avg(CheckOverflow((promote_precision(cast(cast(quantity#16 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(list_price#17 as decimal(12,2)))), DecimalType(18,2)))]) @@ -155,7 +155,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#18,ss_quantity#13,ss_list_price#14] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(2) Project [d_date_sk#19] : : +- *(2) Filter (((isnotnull(d_year#20) && (d_year#20 >= 1999)) && (d_year#20 <= 2001)) && isnotnull(d_date_sk#19)) - : : +- *(2) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : +- *(2) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : :- *(6) Project [cs_quantity#21 AS quantity#22, cs_list_price#23 AS list_price#24] : : +- *(6) SortMergeJoin [cs_sold_date_sk#25], [d_date_sk#19], Inner : : :- *(4) Project [cs_sold_date_sk#25, cs_quantity#21, cs_list_price#23] @@ -163,7 +163,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : : +- *(4) FileScan Hyperspace(Type: CI, Name: JoinIndex26-index-6-cs_sold_date_sk-26, LogVersion: 0) default.catalog_sales[cs_sold_date_sk#25,cs_quantity#21,cs_list_price#23] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cs_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(5) Project [d_date_sk#19] : : +- *(5) Filter (((isnotnull(d_year#20) && (d_year#20 >= 1999)) && (d_year#20 <= 2001)) && isnotnull(d_date_sk#19)) - : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : +- *(5) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : +- *(9) Project [ws_quantity#26 AS quantity#27, ws_list_price#28 AS list_price#29] : +- *(9) SortMergeJoin [ws_sold_date_sk#30], [d_date_sk#19], Inner : :- *(7) Project [ws_sold_date_sk#30, ws_quantity#26, ws_list_price#28] @@ -171,7 +171,7 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 : : +- *(7) FileScan Hyperspace(Type: CI, Name: JoinIndex37-index-9-ws_sold_date_sk-21, LogVersion: 0) default.web_sales[ws_sold_date_sk#30,ws_quantity#26,ws_list_price#28] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ws_sold_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : +- *(8) Project [d_date_sk#19] : +- *(8) Filter (((isnotnull(d_year#20) && (d_year#20 >= 1999)) && (d_year#20 <= 2001)) && isnotnull(d_date_sk#19)) - : +- *(8) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : +- *(8) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#19,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), GreaterThanOrEqual(d_year,1999), LessThanOrEqual(d_year,2001), IsNotNull(d_da..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 +- *(152) HashAggregate(keys=[i_brand_id#8, i_class_id#9, i_category_id#10], functions=[sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2))), count(1)]) +- Exchange hashpartitioning(i_brand_id#8, i_class_id#9, i_category_id#10, 5) +- *(151) HashAggregate(keys=[i_brand_id#8, i_class_id#9, i_category_id#10], functions=[partial_sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#13 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price#14 as decimal(12,2)))), DecimalType(18,2))), partial_count(1)]) @@ -182,13 +182,13 @@ TakeOrderedAndProject(limit=100, orderBy=[channel#1 ASC NULLS FIRST,i_brand_id#2 +- *(150) Sort [d_date_sk#19 ASC NULLS FIRST], false, 0 +- Exchange hashpartitioning(d_date_sk#19, 5) +- *(149) Project [d_date_sk#19] - +- *(149) Filter ((isnotnull(d_week_seq#39) && (d_week_seq#39 = Subquery subquery3085)) && isnotnull(d_date_sk#19)) - : +- Subquery subquery3085 + +- *(149) Filter ((isnotnull(d_week_seq#39) && (d_week_seq#39 = Subquery subquery3034)) && isnotnull(d_date_sk#19)) + : +- Subquery subquery3034 : +- *(1) Project [d_week_seq#39] - : +- *(1) Filter (((((isnotnull(d_dom#40) && isnotnull(d_year#20)) && isnotnull(d_moy#41)) && (d_year#20 = 1999)) && (d_moy#41 = 12)) && (d_dom#40 = 11)) - : +- *(1) FileScan parquet default.date_dim[d_week_seq#39,d_year#20,d_moy#41,d_dom#40] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/date_dim], PartitionFilters: [], PushedFilters: [IsNotNull(d_dom), IsNotNull(d_year), IsNotNull(d_moy), EqualTo(d_year,1999), EqualTo(d_moy,12), ..., ReadSchema: struct + : +- *(1) Filter (((((isnotnull(d_moy#40) && isnotnull(d_dom#41)) && isnotnull(d_year#20)) && (d_year#20 = 1999)) && (d_moy#40 = 12)) && (d_dom#41 = 11)) + : +- *(1) FileScan parquet default.date_dim[d_week_seq#39,d_year#20,d_moy#40,d_dom#41] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/date_dim], PartitionFilters: [], PushedFilters: [IsNotNull(d_moy), IsNotNull(d_dom), IsNotNull(d_year), EqualTo(d_year,1999), EqualTo(d_moy,12), ..., ReadSchema: struct +- *(149) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#19,d_week_seq#39] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_week_seq), IsNotNull(d_date_sk)], ReadSchema: struct - +- Subquery subquery3085 + +- Subquery subquery3034 +- *(1) Project [d_week_seq#39] - +- *(1) Filter (((((isnotnull(d_dom#40) && isnotnull(d_year#20)) && isnotnull(d_moy#41)) && (d_year#20 = 1999)) && (d_moy#41 = 12)) && (d_dom#40 = 11)) - +- *(1) FileScan parquet default.date_dim[d_week_seq#39,d_year#20,d_moy#41,d_dom#40] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/date_dim], PartitionFilters: [], PushedFilters: [IsNotNull(d_dom), IsNotNull(d_year), IsNotNull(d_moy), EqualTo(d_year,1999), EqualTo(d_moy,12), ..., ReadSchema: struct \ No newline at end of file + +- *(1) Filter (((((isnotnull(d_moy#40) && isnotnull(d_dom#41)) && isnotnull(d_year#20)) && (d_year#20 = 1999)) && (d_moy#40 = 12)) && (d_dom#41 = 11)) + +- *(1) FileScan parquet default.date_dim[d_week_seq#39,d_year#20,d_moy#40,d_dom#41] Batched: true, Format: Parquet, Location [not included in comparison]/{warehouse_dir}/date_dim], PartitionFilters: [], PushedFilters: [IsNotNull(d_moy), IsNotNull(d_dom), IsNotNull(d_year), EqualTo(d_year,1999), EqualTo(d_moy,12), ..., ReadSchema: struct \ No newline at end of file diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14b/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14b/simplified.txt index c578e903..6b8a3a10 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14b/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q14b/simplified.txt @@ -27,7 +27,7 @@ TakeOrderedAndProject [channel,channel,i_brand_id,i_brand_id,i_category_id,i_cat WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [cs_list_price,cs_quantity] SortMergeJoin [cs_sold_date_sk,d_date_sk] @@ -40,7 +40,7 @@ TakeOrderedAndProject [channel,channel,i_brand_id,i_brand_id,i_category_id,i_cat WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [ws_list_price,ws_quantity] SortMergeJoin [d_date_sk,ws_sold_date_sk] @@ -53,7 +53,7 @@ TakeOrderedAndProject [channel,channel,i_brand_id,i_brand_id,i_category_id,i_cat WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] HashAggregate [count,count(1),i_brand_id,i_category_id,i_class_id,sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price as decimal(12,2)))), DecimalType(18,2)))] [channel,count,count(1),number_sales,sales,sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price as decimal(12,2)))), DecimalType(18,2))),sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price as decimal(12,2)))), DecimalType(18,2)))] InputAdapter Exchange [i_brand_id,i_category_id,i_class_id] #1 @@ -150,7 +150,7 @@ TakeOrderedAndProject [channel,channel,i_brand_id,i_brand_id,i_category_id,i_cat WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Sort [i_brand_id,i_category_id,i_class_id] InputAdapter @@ -270,7 +270,7 @@ TakeOrderedAndProject [channel,channel,i_brand_id,i_brand_id,i_category_id,i_cat WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [cs_list_price,cs_quantity] SortMergeJoin [cs_sold_date_sk,d_date_sk] @@ -283,7 +283,7 @@ TakeOrderedAndProject [channel,channel,i_brand_id,i_brand_id,i_category_id,i_cat WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Project [ws_list_price,ws_quantity] SortMergeJoin [d_date_sk,ws_sold_date_sk] @@ -296,7 +296,7 @@ TakeOrderedAndProject [channel,channel,i_brand_id,i_brand_id,i_category_id,i_cat WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] HashAggregate [count,count(1),i_brand_id,i_category_id,i_class_id,sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price as decimal(12,2)))), DecimalType(18,2)))] [channel,count,count(1),number_sales,sales,sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price as decimal(12,2)))), DecimalType(18,2))),sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_list_price as decimal(12,2)))), DecimalType(18,2)))] InputAdapter Exchange [i_brand_id,i_category_id,i_class_id] #19 diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q18/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q18/explain.txt index 9bb6884c..5af8d5d5 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q18/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q18/explain.txt @@ -55,7 +55,7 @@ TakeOrderedAndProject(limit=100, orderBy=[ca_country#1 ASC NULLS FIRST,ca_state# : +- Exchange hashpartitioning(d_date_sk#31, 5) : +- *(19) Project [d_date_sk#31] : +- *(19) Filter ((isnotnull(d_year#43) && (d_year#43 = 1998)) && isnotnull(d_date_sk#31)) - : +- *(19) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#31,d_year#43] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,1998), IsNotNull(d_date_sk)], ReadSchema: struct + : +- *(19) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#31,d_year#43] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,1998), IsNotNull(d_date_sk)], ReadSchema: struct +- *(24) Sort [i_item_sk#29 ASC NULLS FIRST], false, 0 +- Exchange hashpartitioning(i_item_sk#29, 5) +- *(23) Project [i_item_sk#29, i_item_id#24] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q18/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q18/simplified.txt index 83d86cd2..4d621251 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q18/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q18/simplified.txt @@ -101,7 +101,7 @@ TakeOrderedAndProject [agg1,agg2,agg3,agg4,agg5,agg6,agg7,ca_country,ca_county,c WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [i_item_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23a/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23a/explain.txt index 26797099..3de0800e 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23a/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23a/explain.txt @@ -44,8 +44,8 @@ CollectLimit 100 : : : +- *(7) FileScan Hyperspace(Type: CI, Name: JoinIndex08-index-2-i_item_sk-17, LogVersion: 0) default.item[i_item_sk#13,i_item_desc#11] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(i_item_sk)], ReadSchema: struct : : +- *(15) Sort [c_customer_sk#7 ASC NULLS FIRST], false, 0 : : +- *(15) Project [c_customer_sk#7] - : : +- *(15) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))#20) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))#20 as decimal(38,8)) > CheckOverflow((0.500000 * promote_precision(cast(Subquery subquery4230 as decimal(32,6)))), DecimalType(38,8)))) - : : : +- Subquery subquery4230 + : : +- *(15) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))#20) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))#20 as decimal(38,8)) > CheckOverflow((0.500000 * promote_precision(cast(Subquery subquery4179 as decimal(32,6)))), DecimalType(38,8)))) + : : : +- Subquery subquery4179 : : : +- *(9) HashAggregate(keys=[], functions=[max(csales#21)]) : : : +- Exchange SinglePartition : : : +- *(8) HashAggregate(keys=[], functions=[partial_max(csales#21)]) @@ -68,7 +68,7 @@ CollectLimit 100 : : : +- Exchange hashpartitioning(d_date_sk#5, 5) : : : +- *(5) Project [d_date_sk#5] : : : +- *(5) Filter (d_year#17 IN (2000,2001,2002,2003) && isnotnull(d_date_sk#5)) - : : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#5,d_year#17] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [In(d_year, [2000,2001,2002,2003]), IsNotNull(d_date_sk)], ReadSchema: struct + : : : +- *(5) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#5,d_year#17] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [In(d_year, [2000,2001,2002,2003]), IsNotNull(d_date_sk)], ReadSchema: struct : : +- *(15) HashAggregate(keys=[c_customer_sk#7], functions=[sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))]) : : +- *(15) HashAggregate(keys=[c_customer_sk#7], functions=[partial_sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))]) : : +- *(15) Project [ss_quantity#18, ss_sales_price#19, c_customer_sk#7] @@ -103,8 +103,8 @@ CollectLimit 100 : : +- ReusedExchange [item_sk#9], Exchange hashpartitioning(item_sk#9, 5) : +- *(35) Sort [c_customer_sk#7 ASC NULLS FIRST], false, 0 : +- *(35) Project [c_customer_sk#7] - : +- *(35) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))#20) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))#20 as decimal(38,8)) > CheckOverflow((0.500000 * promote_precision(cast(Subquery subquery4230 as decimal(32,6)))), DecimalType(38,8)))) - : : +- Subquery subquery4230 + : +- *(35) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))#20) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))#20 as decimal(38,8)) > CheckOverflow((0.500000 * promote_precision(cast(Subquery subquery4179 as decimal(32,6)))), DecimalType(38,8)))) + : : +- Subquery subquery4179 : : +- *(9) HashAggregate(keys=[], functions=[max(csales#21)]) : : +- Exchange SinglePartition : : +- *(8) HashAggregate(keys=[], functions=[partial_max(csales#21)]) @@ -127,7 +127,7 @@ CollectLimit 100 : : +- Exchange hashpartitioning(d_date_sk#5, 5) : : +- *(5) Project [d_date_sk#5] : : +- *(5) Filter (d_year#17 IN (2000,2001,2002,2003) && isnotnull(d_date_sk#5)) - : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#5,d_year#17] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [In(d_year, [2000,2001,2002,2003]), IsNotNull(d_date_sk)], ReadSchema: struct + : : +- *(5) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#5,d_year#17] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [In(d_year, [2000,2001,2002,2003]), IsNotNull(d_date_sk)], ReadSchema: struct : +- *(35) HashAggregate(keys=[c_customer_sk#7], functions=[sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))]) : +- *(35) HashAggregate(keys=[c_customer_sk#7], functions=[partial_sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#18 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#19 as decimal(12,2)))), DecimalType(18,2)))]) : +- *(35) Project [ss_quantity#18, ss_sales_price#19, c_customer_sk#7] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23a/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23a/simplified.txt index d67d3505..5b51024f 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23a/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23a/simplified.txt @@ -117,7 +117,7 @@ CollectLimit WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] HashAggregate [c_customer_sk,sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price as decimal(12,2)))), DecimalType(18,2)))] [sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price as decimal(12,2)))), DecimalType(18,2))),sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price as decimal(12,2)))), DecimalType(18,2)))] HashAggregate [c_customer_sk,ss_quantity,ss_sales_price,sum,sum] [sum,sum] Project [c_customer_sk,ss_quantity,ss_sales_price] @@ -217,7 +217,7 @@ CollectLimit WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] HashAggregate [c_customer_sk,sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price as decimal(12,2)))), DecimalType(18,2)))] [sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price as decimal(12,2)))), DecimalType(18,2))),sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price as decimal(12,2)))), DecimalType(18,2)))] HashAggregate [c_customer_sk,ss_quantity,ss_sales_price,sum,sum] [sum,sum] Project [c_customer_sk,ss_quantity,ss_sales_price] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23b/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23b/explain.txt index e180373c..0f930841 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23b/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23b/explain.txt @@ -46,8 +46,8 @@ TakeOrderedAndProject(limit=100, orderBy=[c_last_name#1 ASC NULLS FIRST,c_first_ : : : +- *(16) Sort [c_customer_sk#9#10 ASC NULLS FIRST], false, 0 : : : +- Exchange hashpartitioning(c_customer_sk#9#10, 5) : : : +- *(15) Project [c_customer_sk#9 AS c_customer_sk#9#10] - : : : +- *(15) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#21 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#22 as decimal(12,2)))), DecimalType(18,2)))#23) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#21 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#22 as decimal(12,2)))), DecimalType(18,2)))#23 as decimal(38,8)) > CheckOverflow((0.500000 * promote_precision(cast(Subquery subquery4330 as decimal(32,6)))), DecimalType(38,8)))) - : : : : +- Subquery subquery4330 + : : : +- *(15) Filter (isnotnull(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#21 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#22 as decimal(12,2)))), DecimalType(18,2)))#23) && (cast(sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#21 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#22 as decimal(12,2)))), DecimalType(18,2)))#23 as decimal(38,8)) > CheckOverflow((0.500000 * promote_precision(cast(Subquery subquery4279 as decimal(32,6)))), DecimalType(38,8)))) + : : : : +- Subquery subquery4279 : : : : +- *(9) HashAggregate(keys=[], functions=[max(csales#24)]) : : : : +- Exchange SinglePartition : : : : +- *(8) HashAggregate(keys=[], functions=[partial_max(csales#24)]) @@ -70,7 +70,7 @@ TakeOrderedAndProject(limit=100, orderBy=[c_last_name#1 ASC NULLS FIRST,c_first_ : : : : +- Exchange hashpartitioning(d_date_sk#7, 5) : : : : +- *(5) Project [d_date_sk#7] : : : : +- *(5) Filter (d_year#20 IN (2000,2001,2002,2003) && isnotnull(d_date_sk#7)) - : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#7,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [In(d_year, [2000,2001,2002,2003]), IsNotNull(d_date_sk)], ReadSchema: struct + : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#7,d_year#20] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [In(d_year, [2000,2001,2002,2003]), IsNotNull(d_date_sk)], ReadSchema: struct : : : +- *(15) HashAggregate(keys=[c_customer_sk#9], functions=[sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#21 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#22 as decimal(12,2)))), DecimalType(18,2)))]) : : : +- *(15) HashAggregate(keys=[c_customer_sk#9], functions=[partial_sum(CheckOverflow((promote_precision(cast(cast(ss_quantity#21 as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price#22 as decimal(12,2)))), DecimalType(18,2)))]) : : : +- *(15) Project [ss_quantity#21, ss_sales_price#22, c_customer_sk#9] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23b/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23b/simplified.txt index b28cafd6..882ced61 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23b/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q23b/simplified.txt @@ -119,7 +119,7 @@ TakeOrderedAndProject [c_first_name,c_last_name,sales] WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] HashAggregate [c_customer_sk,sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price as decimal(12,2)))), DecimalType(18,2)))] [sum,sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price as decimal(12,2)))), DecimalType(18,2))),sum(CheckOverflow((promote_precision(cast(cast(ss_quantity as decimal(10,0)) as decimal(12,2))) * promote_precision(cast(ss_sales_price as decimal(12,2)))), DecimalType(18,2)))] HashAggregate [c_customer_sk,ss_quantity,ss_sales_price,sum,sum] [sum,sum] Project [c_customer_sk,ss_quantity,ss_sales_price] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q26/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q26/explain.txt index 038bf47d..791ab3e6 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q26/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q26/explain.txt @@ -25,13 +25,13 @@ TakeOrderedAndProject(limit=100, orderBy=[i_item_id#1 ASC NULLS FIRST], output=[ : : : +- *(4) Sort [cd_demo_sk#17 ASC NULLS FIRST], false, 0 : : : +- Exchange hashpartitioning(cd_demo_sk#17, 5) : : : +- *(3) Project [cd_demo_sk#17] - : : : +- *(3) Filter ((((((isnotnull(cd_education_status#18) && isnotnull(cd_gender#19)) && isnotnull(cd_marital_status#20)) && (cd_gender#19 = M)) && (cd_marital_status#20 = S)) && (cd_education_status#18 = College)) && isnotnull(cd_demo_sk#17)) - : : : +- *(3) FileScan Hyperspace(Type: CI, Name: JoinIndex25-index-18-cd_demo_sk-8, LogVersion: 0) default.customer_demographics[cd_demo_sk#17,cd_gender#19,cd_marital_status#20,cd_education_status#18] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cd_education_status), IsNotNull(cd_gender), IsNotNull(cd_marital_status), EqualTo(cd_g..., ReadSchema: struct + : : : +- *(3) Filter ((((((isnotnull(cd_education_status#18) && isnotnull(cd_marital_status#19)) && isnotnull(cd_gender#20)) && (cd_gender#20 = M)) && (cd_marital_status#19 = S)) && (cd_education_status#18 = College)) && isnotnull(cd_demo_sk#17)) + : : : +- *(3) FileScan Hyperspace(Type: CI, Name: JoinIndex25-index-18-cd_demo_sk-8, LogVersion: 0) default.customer_demographics[cd_demo_sk#17,cd_gender#20,cd_marital_status#19,cd_education_status#18] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cd_education_status), IsNotNull(cd_marital_status), IsNotNull(cd_gender), EqualTo(cd_g..., ReadSchema: struct : : +- *(8) Sort [d_date_sk#15 ASC NULLS FIRST], false, 0 : : +- Exchange hashpartitioning(d_date_sk#15, 5) : : +- *(7) Project [d_date_sk#15] : : +- *(7) Filter ((isnotnull(d_year#21) && (d_year#21 = 2000)) && isnotnull(d_date_sk#15)) - : : +- *(7) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#15,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct + : : +- *(7) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#15,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct : +- *(12) Sort [i_item_sk#13 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(i_item_sk#13, 5) : +- *(11) Project [i_item_sk#13, i_item_id#1] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q26/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q26/simplified.txt index 5ea7eb14..3ec524cd 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q26/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q26/simplified.txt @@ -57,7 +57,7 @@ TakeOrderedAndProject [agg1,agg2,agg3,agg4,i_item_id] WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [i_item_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q27/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q27/explain.txt index df728fdd..1a1575a7 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q27/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q27/explain.txt @@ -22,13 +22,13 @@ TakeOrderedAndProject(limit=100, orderBy=[i_item_id#1 ASC NULLS FIRST,s_state#2 : : : : +- *(1) Filter (((isnotnull(ss_cdemo_sk#23) && isnotnull(ss_sold_date_sk#21)) && isnotnull(ss_store_sk#19)) && isnotnull(ss_item_sk#17)) : : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex19-index-47-ss_cdemo_sk-16, LogVersion: 0) default.store_sales[ss_sold_date_sk#21,ss_item_sk#17,ss_cdemo_sk#23,ss_store_sk#19,ss_quantity#9,ss_list_price#10,ss_sales_price#12,ss_coupon_amt#11] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_cdemo_sk), IsNotNull(ss_sold_date_sk), IsNotNull(ss_store_sk), IsNotNull(ss_item_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : +- *(2) Filter ((((((isnotnull(cd_education_status#25) && isnotnull(cd_marital_status#26)) && isnotnull(cd_gender#27)) && (cd_gender#27 = M)) && (cd_marital_status#26 = S)) && (cd_education_status#25 = College)) && isnotnull(cd_demo_sk#24)) + : : : +- *(2) FileScan Hyperspace(Type: CI, Name: JoinIndex25-index-18-cd_demo_sk-8, LogVersion: 0) default.customer_demographics[cd_demo_sk#24,cd_gender#27,cd_marital_status#26,cd_education_status#25] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cd_education_status), IsNotNull(cd_marital_status), IsNotNull(cd_gender), EqualTo(cd_g..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(6) Sort [d_date_sk#22 ASC NULLS FIRST], false, 0 : : +- Exchange hashpartitioning(d_date_sk#22, 5) : : +- *(5) Project [d_date_sk#22] : : +- *(5) Filter ((isnotnull(d_year#28) && (d_year#28 = 2002)) && isnotnull(d_date_sk#22)) - : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#22,d_year#28] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct + : : +- *(5) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#22,d_year#28] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct : +- *(10) Sort [s_store_sk#20 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(s_store_sk#20, 5) : +- *(9) Project [s_store_sk#20, s_state#16] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q27/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q27/simplified.txt index 0be530a8..6836c01e 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q27/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q27/simplified.txt @@ -50,7 +50,7 @@ TakeOrderedAndProject [agg1,agg2,agg3,agg4,g_state,i_item_id,s_state] WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [s_store_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q29/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q29/explain.txt index 0d460db8..0f62b8b8 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q29/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q29/explain.txt @@ -32,18 +32,18 @@ TakeOrderedAndProject(limit=100, orderBy=[i_item_id#1 ASC NULLS FIRST,i_item_des : : : : : : :- *(2) Sort [cast(ss_customer_sk#25 as bigint) ASC NULLS FIRST, cast(ss_item_sk#11 as bigint) ASC NULLS FIRST, cast(ss_ticket_number#26 as bigint) ASC NULLS FIRST], false, 0 : : : : : : : +- Exchange hashpartitioning(cast(ss_customer_sk#25 as bigint), cast(ss_item_sk#11 as bigint), cast(ss_ticket_number#26 as bigint), 5) : : : : : : : +- *(1) Project [ss_sold_date_sk#19, ss_item_sk#11, ss_customer_sk#25, ss_store_sk#13, ss_ticket_number#26, ss_quantity#8] - : : : : : : : +- *(1) Filter ((((isnotnull(ss_customer_sk#25) && isnotnull(ss_ticket_number#26)) && isnotnull(ss_item_sk#11)) && isnotnull(ss_sold_date_sk#19)) && isnotnull(ss_store_sk#13)) - : : : : : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#19,ss_item_sk#11,ss_customer_sk#25,ss_store_sk#13,ss_ticket_number#26,ss_quantity#8] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_customer_sk), IsNotNull(ss_ticket_number), IsNotNull(ss_item_sk), IsNotNull(ss_sold..., ReadSchema: struct + : : : : : +- *(7) Filter ((isnotnull(cs_item_sk#24) && isnotnull(cs_bill_customer_sk#23)) && isnotnull(cs_sold_date_sk#15)) + : : : : : +- *(7) FileScan Hyperspace(Type: CI, Name: JoinIndex26-index-6-cs_sold_date_sk-26, LogVersion: 0) default.catalog_sales[cs_sold_date_sk#15,cs_bill_customer_sk#23,cs_item_sk#24,cs_quantity#10] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cs_item_sk), IsNotNull(cs_bill_customer_sk), IsNotNull(cs_sold_date_sk)], ReadSchema: struct : : : : +- *(12) Sort [d_date_sk#20 ASC NULLS FIRST], false, 0 : : : : +- Exchange hashpartitioning(d_date_sk#20, 5) : : : : +- *(11) Project [d_date_sk#20] @@ -52,13 +52,13 @@ TakeOrderedAndProject(limit=100, orderBy=[i_item_id#1 ASC NULLS FIRST,i_item_des : : : +- *(16) Sort [cast(d_date_sk#18 as bigint) ASC NULLS FIRST], false, 0 : : : +- Exchange hashpartitioning(cast(d_date_sk#18 as bigint), 5) : : : +- *(15) Project [d_date_sk#18] - : : : +- *(15) Filter (((((isnotnull(d_year#30) && isnotnull(d_moy#31)) && (d_moy#31 >= 9)) && (d_moy#31 <= 12)) && (d_year#30 = 1999)) && isnotnull(d_date_sk#18)) - : : : +- *(15) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#18,d_year#30,d_moy#31] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), IsNotNull(d_moy), GreaterThanOrEqual(d_moy,9), LessThanOrEqual(d_moy,12), Equ..., ReadSchema: struct + : : : +- *(15) Filter (((((isnotnull(d_moy#30) && isnotnull(d_year#31)) && (d_moy#30 >= 9)) && (d_moy#30 <= 12)) && (d_year#31 = 1999)) && isnotnull(d_date_sk#18)) + : : : +- *(15) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#18,d_year#31,d_moy#30] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_moy), IsNotNull(d_year), GreaterThanOrEqual(d_moy,9), LessThanOrEqual(d_moy,12), Equ..., ReadSchema: struct : : +- *(20) Sort [d_date_sk#16 ASC NULLS FIRST], false, 0 : : +- Exchange hashpartitioning(d_date_sk#16, 5) : : +- *(19) Project [d_date_sk#16] : : +- *(19) Filter (d_year#32 IN (1999,2000,2001) && isnotnull(d_date_sk#16)) - : : +- *(19) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#16,d_year#32] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [In(d_year, [1999,2000,2001]), IsNotNull(d_date_sk)], ReadSchema: struct + : : +- *(19) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#16,d_year#32] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [In(d_year, [1999,2000,2001]), IsNotNull(d_date_sk)], ReadSchema: struct : +- *(24) Sort [s_store_sk#14 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(s_store_sk#14, 5) : +- *(23) Project [s_store_sk#14, s_store_id#3, s_store_name#4] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q29/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q29/simplified.txt index 32c1684b..502928d4 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q29/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q29/simplified.txt @@ -108,7 +108,7 @@ TakeOrderedAndProject [catalog_sales_quantity,i_item_desc,i_item_id,s_store_id,s WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [s_store_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q30/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q30/explain.txt index dc1b7233..ac7912ad 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q30/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q30/explain.txt @@ -31,7 +31,7 @@ TakeOrderedAndProject(limit=100, orderBy=[c_customer_id#1 ASC NULLS FIRST,c_salu : : : : +- Exchange hashpartitioning(cast(d_date_sk#26 as bigint), 5) : : : : +- *(3) Project [d_date_sk#26] : : : : +- *(3) Filter ((isnotnull(d_year#27) && (d_year#27 = 2002)) && isnotnull(d_date_sk#26)) - : : : : +- *(3) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#26,d_year#27] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct + : : : : +- *(3) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#26,d_year#27] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct : : : +- *(8) Sort [cast(ca_address_sk#15 as bigint) ASC NULLS FIRST], false, 0 : : : +- Exchange hashpartitioning(cast(ca_address_sk#15 as bigint), 5) : : : +- *(7) Project [ca_address_sk#15, ca_state#22] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q30/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q30/simplified.txt index 2f9bc476..a6c53942 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q30/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q30/simplified.txt @@ -57,7 +57,7 @@ TakeOrderedAndProject [c_birth_country,c_birth_day,c_birth_month,c_birth_year,c_ WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [ca_address_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q36/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q36/explain.txt index a0e1e287..c909481d 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q36/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q36/explain.txt @@ -23,7 +23,7 @@ TakeOrderedAndProject(limit=100, orderBy=[lochierarchy#1 DESC NULLS LAST,CASE WH : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#20,ss_item_sk#18,ss_store_sk#16,ss_ext_sales_price#11,ss_net_profit#10] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_sold_date_sk), IsNotNull(ss_item_sk), IsNotNull(ss_store_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : +- *(2) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#21,d_year#22] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : +- *(6) Sort [i_item_sk#19 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(i_item_sk#19, 5) : +- *(5) Project [i_item_sk#19, i_class#15, i_category#14] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q36/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q36/simplified.txt index 6f750d8b..5942f998 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q36/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q36/simplified.txt @@ -41,7 +41,7 @@ TakeOrderedAndProject [gross_margin,i_category,i_class,lochierarchy,rank_within_ WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [i_item_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q4/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q4/explain.txt index 491ff83d..d5e2af60 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q4/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q4/explain.txt @@ -32,7 +32,7 @@ TakeOrderedAndProject(limit=100, orderBy=[customer_id#1 ASC NULLS FIRST,customer : : : : : : +- Exchange hashpartitioning(d_date_sk#32, 5) : : : : : : +- *(5) Project [d_date_sk#32, d_year#26] : : : : : : +- *(5) Filter ((isnotnull(d_year#26) && (d_year#26 = 2001)) && isnotnull(d_date_sk#32)) - : : : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#32,d_year#26] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct + : : : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#32,d_year#26] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct : : : : : :- LocalTableScan , [customer_id#35, year_total#36] : : : : : +- LocalTableScan , [customer_id#37, year_total#38] : : : : +- *(18) Sort [customer_id#1 ASC NULLS FIRST], false, 0 @@ -49,7 +49,7 @@ TakeOrderedAndProject(limit=100, orderBy=[customer_id#1 ASC NULLS FIRST,customer : : : : : +- Exchange hashpartitioning(d_date_sk#32, 5) : : : : : +- *(14) Project [d_date_sk#32, d_year#26] : : : : : +- *(14) Filter ((isnotnull(d_year#26) && (d_year#26 = 2002)) && isnotnull(d_date_sk#32)) - : : : : : +- *(14) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#32,d_year#26] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct + : : : : : +- *(14) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#32,d_year#26] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct : : : : :- LocalTableScan , [customer_id#35, customer_first_name#39, customer_last_name#40, customer_preferred_cust_flag#41, customer_birth_country#42, customer_login#43, customer_email_address#44, year_total#36] : : : : +- LocalTableScan , [customer_id#37, customer_first_name#45, customer_last_name#46, customer_preferred_cust_flag#47, customer_birth_country#48, customer_login#49, customer_email_address#50, year_total#38] : : : +- *(28) Sort [customer_id#18 ASC NULLS FIRST], false, 0 diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q4/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q4/simplified.txt index 3c09dd92..4d51f071 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q4/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q4/simplified.txt @@ -58,7 +58,7 @@ TakeOrderedAndProject [customer_birth_country,customer_email_address,customer_fi WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] LocalTableScan [customer_id,year_total] [customer_id,year_total] LocalTableScan [customer_id,year_total] [customer_id,year_total] InputAdapter @@ -88,7 +88,7 @@ TakeOrderedAndProject [customer_birth_country,customer_email_address,customer_fi WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] LocalTableScan [customer_birth_country,customer_email_address,customer_first_name,customer_id,customer_last_name,customer_login,customer_preferred_cust_flag,year_total] [customer_birth_country,customer_email_address,customer_first_name,customer_id,customer_last_name,customer_login,customer_preferred_cust_flag,year_total] LocalTableScan [customer_birth_country,customer_email_address,customer_first_name,customer_id,customer_last_name,customer_login,customer_preferred_cust_flag,year_total] [customer_birth_country,customer_email_address,customer_first_name,customer_id,customer_last_name,customer_login,customer_preferred_cust_flag,year_total] InputAdapter diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q48/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q48/explain.txt index b0ecdc8e..c3b349c1 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q48/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q48/explain.txt @@ -36,4 +36,4 @@ +- Exchange hashpartitioning(d_date_sk#3, 5) +- *(13) Project [d_date_sk#3] +- *(13) Filter ((isnotnull(d_year#16) && (d_year#16 = 2001)) && isnotnull(d_date_sk#3)) - +- *(13) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#3,d_year#16] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct \ No newline at end of file + +- *(13) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#3,d_year#16] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct \ No newline at end of file diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q48/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q48/simplified.txt index 7fcf2cdf..7c84cce2 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q48/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q48/simplified.txt @@ -66,4 +66,4 @@ WholeStageCodegen WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q50/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q50/explain.txt index 49fe3b4c..94e26209 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q50/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q50/explain.txt @@ -20,13 +20,13 @@ TakeOrderedAndProject(limit=100, orderBy=[s_store_name#1 ASC NULLS FIRST,s_compa : : : :- *(2) Sort [cast(ss_ticket_number#22 as bigint) ASC NULLS FIRST, cast(ss_item_sk#23 as bigint) ASC NULLS FIRST, cast(ss_customer_sk#24 as bigint) ASC NULLS FIRST], false, 0 : : : : +- Exchange hashpartitioning(cast(ss_ticket_number#22 as bigint), cast(ss_item_sk#23 as bigint), cast(ss_customer_sk#24 as bigint), 5) : : : : +- *(1) Project [ss_sold_date_sk#17, ss_item_sk#23, ss_customer_sk#24, ss_store_sk#20, ss_ticket_number#22] - : : : : +- *(1) Filter ((((isnotnull(ss_customer_sk#24) && isnotnull(ss_ticket_number#22)) && isnotnull(ss_item_sk#23)) && isnotnull(ss_store_sk#20)) && isnotnull(ss_sold_date_sk#17)) - : : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#17,ss_item_sk#23,ss_customer_sk#24,ss_store_sk#20,ss_ticket_number#22] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_customer_sk), IsNotNull(ss_ticket_number), IsNotNull(ss_item_sk), IsNotNull(ss_stor..., ReadSchema: struct + : : : : +- *(1) Filter ((((isnotnull(ss_item_sk#23) && isnotnull(ss_ticket_number#22)) && isnotnull(ss_customer_sk#24)) && isnotnull(ss_store_sk#20)) && isnotnull(ss_sold_date_sk#17)) + : : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex12-index-1-ss_sold_date_sk-21, LogVersion: 0) default.store_sales[ss_sold_date_sk#17,ss_item_sk#23,ss_customer_sk#24,ss_store_sk#20,ss_ticket_number#22] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_item_sk), IsNotNull(ss_ticket_number), IsNotNull(ss_customer_sk), IsNotNull(ss_stor..., ReadSchema: struct : : : +- *(4) Sort [sr_ticket_number#25 ASC NULLS FIRST, sr_item_sk#26 ASC NULLS FIRST, sr_customer_sk#27 ASC NULLS FIRST], false, 0 : : : +- Exchange hashpartitioning(sr_ticket_number#25, sr_item_sk#26, sr_customer_sk#27, 5) : : : +- *(3) Project [sr_returned_date_sk#16, sr_item_sk#26, sr_customer_sk#27, sr_ticket_number#25] - : : : +- *(3) Filter (((isnotnull(sr_customer_sk#27) && isnotnull(sr_ticket_number#25)) && isnotnull(sr_item_sk#26)) && isnotnull(sr_returned_date_sk#16)) - : : : +- *(3) FileScan Hyperspace(Type: CI, Name: JoinIndex21-index-20-sr_item_sk-7, LogVersion: 0) default.store_returns[sr_returned_date_sk#16,sr_item_sk#26,sr_customer_sk#27,sr_ticket_number#25] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(sr_customer_sk), IsNotNull(sr_ticket_number), IsNotNull(sr_item_sk), IsNotNull(sr_retu..., ReadSchema: struct + : : : +- *(3) Filter (((isnotnull(sr_ticket_number#25) && isnotnull(sr_customer_sk#27)) && isnotnull(sr_item_sk#26)) && isnotnull(sr_returned_date_sk#16)) + : : : +- *(3) FileScan Hyperspace(Type: CI, Name: JoinIndex21-index-20-sr_item_sk-7, LogVersion: 0) default.store_returns[sr_returned_date_sk#16,sr_item_sk#26,sr_customer_sk#27,sr_ticket_number#25] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(sr_ticket_number), IsNotNull(sr_customer_sk), IsNotNull(sr_item_sk), IsNotNull(sr_retu..., ReadSchema: struct : : +- *(8) Sort [s_store_sk#21 ASC NULLS FIRST], false, 0 : : +- Exchange hashpartitioning(s_store_sk#21, 5) : : +- *(7) Project [s_store_sk#21, s_store_name#1, s_company_id#2, s_street_number#3, s_street_name#4, s_street_type#5, s_suite_number#6, s_city#7, s_county#8, s_state#9, s_zip#10] @@ -36,7 +36,7 @@ TakeOrderedAndProject(limit=100, orderBy=[s_store_name#1 ASC NULLS FIRST,s_compa : +- Exchange hashpartitioning(d_date_sk#19, 5) : +- *(11) Project [d_date_sk#19] : +- *(11) Filter isnotnull(d_date_sk#19) - : +- *(11) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#19] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_date_sk)], ReadSchema: struct + : +- *(11) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#19] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_date_sk)], ReadSchema: struct +- *(16) Sort [cast(d_date_sk#18 as bigint) ASC NULLS FIRST], false, 0 +- Exchange hashpartitioning(cast(d_date_sk#18 as bigint), 5) +- *(15) Project [d_date_sk#18] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q50/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q50/simplified.txt index 1a696264..6253658c 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q50/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q50/simplified.txt @@ -66,7 +66,7 @@ TakeOrderedAndProject [30 days ,31 - 60 days ,61 - 90 days ,91 - 120 days ,>120 WholeStageCodegen Project [d_date_sk] Filter [d_date_sk] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk] [d_date_sk] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk] [d_date_sk] InputAdapter WholeStageCodegen Sort [d_date_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q64/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q64/explain.txt index 610b8af6..1e54ab58 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q64/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q64/explain.txt @@ -105,12 +105,12 @@ : : : : : : : : : : : : : : : +- Exchange hashpartitioning(d_date_sk#74, 5) : : : : : : : : : : : : : : : +- *(15) Project [d_date_sk#74, d_year#38] : : : : : : : : : : : : : : : +- *(15) Filter ((isnotnull(d_year#38) && (d_year#38 = 1999)) && isnotnull(d_date_sk#74)) - : : : : : : : : : : : : : : : +- *(15) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#74,d_year#38] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,1999), IsNotNull(d_date_sk)], ReadSchema: struct + : : : : : : : : : : : : : : : +- *(15) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#74,d_year#38] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,1999), IsNotNull(d_date_sk)], ReadSchema: struct : : : : : : : : : : : : : : +- *(20) Sort [s_store_sk#72 ASC NULLS FIRST], false, 0 : : : : : : : : : : : : : : +- Exchange hashpartitioning(s_store_sk#72, 5) : : : : : : : : : : : : : : +- *(19) Project [s_store_sk#72, s_store_name#28, s_zip#29] - : : : : : : : : : : : : : : +- *(19) Filter ((isnotnull(s_store_sk#72) && isnotnull(s_zip#29)) && isnotnull(s_store_name#28)) - : : : : : : : : : : : : : : +- *(19) FileScan Hyperspace(Type: CI, Name: JoinIndex24-index-4-s_store_sk-15, LogVersion: 0) default.store[s_store_sk#72,s_store_name#28,s_zip#29] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(s_store_sk), IsNotNull(s_zip), IsNotNull(s_store_name)], ReadSchema: struct + : : : : : : : : : : : : : : +- *(19) Filter ((isnotnull(s_store_sk#72) && isnotnull(s_store_name#28)) && isnotnull(s_zip#29)) + : : : : : : : : : : : : : : +- *(19) FileScan Hyperspace(Type: CI, Name: JoinIndex24-index-4-s_store_sk-15, LogVersion: 0) default.store[s_store_sk#72,s_store_name#28,s_zip#29] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(s_store_sk), IsNotNull(s_store_name), IsNotNull(s_zip)], ReadSchema: struct : : : : : : : : : : : : : +- *(24) Sort [c_customer_sk#70 ASC NULLS FIRST], false, 0 : : : : : : : : : : : : : +- Exchange hashpartitioning(c_customer_sk#70, 5) : : : : : : : : : : : : : +- *(23) Project [c_customer_sk#70, c_current_cdemo_sk#59, c_current_hdemo_sk#53, c_current_addr_sk#49, c_first_shipto_date_sk#65, c_first_sales_date_sk#67] @@ -120,7 +120,7 @@ : : : : : : : : : : : : +- Exchange hashpartitioning(d_date_sk#68, 5) : : : : : : : : : : : : +- *(27) Project [d_date_sk#68, d_year#39] : : : : : : : : : : : : +- *(27) Filter isnotnull(d_date_sk#68) - : : : : : : : : : : : : +- *(27) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#68,d_year#39] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_date_sk)], ReadSchema: struct + : : : : : : : : : : : : +- *(27) FileScan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim[d_date_sk#68,d_year#39] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_date_sk)], ReadSchema: struct : : : : : : : : : : : +- *(32) Sort [d_date_sk#66 ASC NULLS FIRST], false, 0 : : : : : : : : : : : +- ReusedExchange [d_date_sk#66, d_year#40], Exchange hashpartitioning(d_date_sk#68, 5) : : : : : : : : : : +- *(36) Sort [cd_demo_sk#64 ASC NULLS FIRST], false, 0 @@ -229,7 +229,7 @@ : : : : : : : : : : : : : : +- Exchange hashpartitioning(d_date_sk#74, 5) : : : : : : : : : : : : : : +- *(89) Project [d_date_sk#74, d_year#38] : : : : : : : : : : : : : : +- *(89) Filter ((isnotnull(d_year#38) && (d_year#38 = 2000)) && isnotnull(d_date_sk#74)) - : : : : : : : : : : : : : : +- *(89) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#74,d_year#38] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct + : : : : : : : : : : : : : : +- *(89) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#74,d_year#38] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct : : : : : : : : : : : : : +- *(94) Sort [s_store_sk#72 ASC NULLS FIRST], false, 0 : : : : : : : : : : : : : +- ReusedExchange [s_store_sk#72, s_store_name#28, s_zip#29], Exchange hashpartitioning(s_store_sk#72, 5) : : : : : : : : : : : : +- *(98) Sort [c_customer_sk#70 ASC NULLS FIRST], false, 0 diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q64/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q64/simplified.txt index 7fe828f6..7fd605c9 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q64/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q64/simplified.txt @@ -199,7 +199,7 @@ WholeStageCodegen WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [s_store_sk] @@ -226,7 +226,7 @@ WholeStageCodegen WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: JoinIndex03-index-0-d_date_sk-10, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [d_date_sk] @@ -441,7 +441,7 @@ WholeStageCodegen WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [s_store_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q7/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q7/explain.txt index e19be10d..835b013c 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q7/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q7/explain.txt @@ -21,13 +21,13 @@ TakeOrderedAndProject(limit=100, orderBy=[i_item_id#1 ASC NULLS FIRST], output=[ : : : : +- *(1) Filter (((isnotnull(ss_cdemo_sk#16) && isnotnull(ss_sold_date_sk#14)) && isnotnull(ss_item_sk#12)) && isnotnull(ss_promo_sk#10)) : : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex19-index-47-ss_cdemo_sk-16, LogVersion: 0) default.store_sales[ss_sold_date_sk#14,ss_item_sk#12,ss_cdemo_sk#16,ss_promo_sk#10,ss_quantity#6,ss_list_price#7,ss_sales_price#9,ss_coupon_amt#8] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_cdemo_sk), IsNotNull(ss_sold_date_sk), IsNotNull(ss_item_sk), IsNotNull(ss_promo_sk)], ReadSchema: struct, SelectedBucketsCount: 200 out of 200 + : : : +- *(2) Filter ((((((isnotnull(cd_education_status#18) && isnotnull(cd_marital_status#19)) && isnotnull(cd_gender#20)) && (cd_gender#20 = M)) && (cd_marital_status#19 = S)) && (cd_education_status#18 = College)) && isnotnull(cd_demo_sk#17)) + : : : +- *(2) FileScan Hyperspace(Type: CI, Name: JoinIndex25-index-18-cd_demo_sk-8, LogVersion: 0) default.customer_demographics[cd_demo_sk#17,cd_gender#20,cd_marital_status#19,cd_education_status#18] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cd_education_status), IsNotNull(cd_marital_status), IsNotNull(cd_gender), EqualTo(cd_g..., ReadSchema: struct, SelectedBucketsCount: 200 out of 200 : : +- *(6) Sort [d_date_sk#15 ASC NULLS FIRST], false, 0 : : +- Exchange hashpartitioning(d_date_sk#15, 5) : : +- *(5) Project [d_date_sk#15] : : +- *(5) Filter ((isnotnull(d_year#21) && (d_year#21 = 2000)) && isnotnull(d_date_sk#15)) - : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#15,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct + : : +- *(5) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#15,d_year#21] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct : +- *(10) Sort [i_item_sk#13 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(i_item_sk#13, 5) : +- *(9) Project [i_item_sk#13, i_item_id#1] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q7/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q7/simplified.txt index 0ed05cf4..2939215b 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q7/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q7/simplified.txt @@ -49,7 +49,7 @@ TakeOrderedAndProject [agg1,agg2,agg3,agg4,i_item_id] WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [i_item_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q74/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q74/explain.txt index f0caf3ac..c8dd1e18 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q74/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q74/explain.txt @@ -28,7 +28,7 @@ TakeOrderedAndProject(limit=100, orderBy=[customer_id#1 ASC NULLS FIRST,customer : : : : +- Exchange hashpartitioning(d_date_sk#17, 5) : : : : +- *(5) Project [d_date_sk#17, d_year#14] : : : : +- *(5) Filter (((isnotnull(d_year#14) && d_year#14 IN (2001,2002)) && (d_year#14 = 2001)) && isnotnull(d_date_sk#17)) - : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#17,d_year#14] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), In(d_year, [2001,2002]), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct + : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#17,d_year#14] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), In(d_year, [2001,2002]), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct : : : +- LocalTableScan , [customer_id#20, year_total#21] : : +- *(18) Sort [customer_id#1 ASC NULLS FIRST], false, 0 : : +- Exchange hashpartitioning(customer_id#1, 5) @@ -44,7 +44,7 @@ TakeOrderedAndProject(limit=100, orderBy=[customer_id#1 ASC NULLS FIRST,customer : : : +- Exchange hashpartitioning(d_date_sk#17, 5) : : : +- *(14) Project [d_date_sk#17, d_year#14] : : : +- *(14) Filter (((isnotnull(d_year#14) && d_year#14 IN (2001,2002)) && (d_year#14 = 2002)) && isnotnull(d_date_sk#17)) - : : : +- *(14) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#17,d_year#14] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), In(d_year, [2001,2002]), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct + : : : +- *(14) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#17,d_year#14] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), In(d_year, [2001,2002]), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct : : +- LocalTableScan , [customer_id#20, customer_first_name#22, customer_last_name#23, year_total#21] : +- *(28) Sort [customer_id#10 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(customer_id#10, 5) diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q74/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q74/simplified.txt index d13b950e..03d612f9 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q74/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q74/simplified.txt @@ -50,7 +50,7 @@ TakeOrderedAndProject [customer_first_name,customer_id,customer_last_name] WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] LocalTableScan [customer_id,year_total] [customer_id,year_total] InputAdapter WholeStageCodegen @@ -79,7 +79,7 @@ TakeOrderedAndProject [customer_first_name,customer_id,customer_last_name] WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] LocalTableScan [customer_first_name,customer_id,customer_last_name,year_total] [customer_first_name,customer_id,customer_last_name,year_total] InputAdapter WholeStageCodegen diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q75/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q75/explain.txt index f0b26a85..adb59bea 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q75/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q75/explain.txt @@ -29,13 +29,13 @@ TakeOrderedAndProject(limit=100, orderBy=[sales_cnt_diff#1 ASC NULLS FIRST], out : : : : : : +- *(1) Filter (isnotnull(cs_item_sk#28) && isnotnull(cs_sold_date_sk#31)) : : : : : : +- *(1) FileScan Hyperspace(Type: CI, Name: JoinIndex27-index-10-cs_item_sk-22, LogVersion: 0) default.catalog_sales[cs_sold_date_sk#31,cs_item_sk#28,cs_order_number#27,cs_quantity#23,cs_ext_sales_price#25] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(cs_item_sk), IsNotNull(cs_sold_date_sk)], ReadSchema: struct + : : : : +- *(5) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#32,d_year#12] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2002), IsNotNull(d_date_sk)], ReadSchema: struct : : : +- *(10) Sort [cr_order_number#29 ASC NULLS FIRST, cr_item_sk#30 ASC NULLS FIRST], false, 0 : : : +- Exchange hashpartitioning(cr_order_number#29, cr_item_sk#30, 5) : : : +- *(9) Project [cr_item_sk#30, cr_order_number#29, cr_return_quantity#24, cr_return_amount#26] @@ -55,8 +55,8 @@ TakeOrderedAndProject(limit=100, orderBy=[sales_cnt_diff#1 ASC NULLS FIRST], out : : : : : +- *(12) Filter (isnotnull(ss_item_sk#42) && isnotnull(ss_sold_date_sk#45)) : : : : : +- *(12) FileScan Hyperspace(Type: CI, Name: JoinIndex13-index-3-ss_item_sk-16, LogVersion: 0) default.store_sales[ss_sold_date_sk#45,ss_item_sk#42,ss_ticket_number#41,ss_quantity#35,ss_ext_sales_price#38] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ss_item_sk), IsNotNull(ss_sold_date_sk)], ReadSchema: struct + : +- *(33) Filter (isnotnull(wr_item_sk#55) && isnotnull(wr_order_number#54)) + : +- *(33) FileScan Hyperspace(Type: CI, Name: JoinIndex41-index-36-wr_item_sk-11, LogVersion: 0) default.web_returns[wr_item_sk#55,wr_order_number#54,wr_return_quantity#47,wr_return_amt#50] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(wr_item_sk), IsNotNull(wr_order_number)], ReadSchema: struct +- *(78) Sort [i_brand_id#17 ASC NULLS FIRST, i_class_id#18 ASC NULLS FIRST, i_category_id#19 ASC NULLS FIRST, i_manufact_id#20 ASC NULLS FIRST], false, 0 +- Exchange hashpartitioning(i_brand_id#17, i_class_id#18, i_category_id#19, i_manufact_id#20, 5) +- *(77) HashAggregate(keys=[d_year#11, i_brand_id#17, i_class_id#18, i_category_id#19, i_manufact_id#20], functions=[sum(cast(sales_cnt#21 as bigint)), sum(UnscaledValue(sales_amt#22))]) @@ -112,7 +112,7 @@ TakeOrderedAndProject(limit=100, orderBy=[sales_cnt_diff#1 ASC NULLS FIRST], out : : : +- Exchange hashpartitioning(d_date_sk#57, 5) : : : +- *(44) Project [d_date_sk#57, d_year#11] : : : +- *(44) Filter ((isnotnull(d_year#11) && (d_year#11 = 2001)) && isnotnull(d_date_sk#57)) - : : : +- *(44) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#57,d_year#11] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct + : : : +- *(44) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#57,d_year#11] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2001), IsNotNull(d_date_sk)], ReadSchema: struct : : +- *(49) Sort [cr_order_number#29 ASC NULLS FIRST, cr_item_sk#30 ASC NULLS FIRST], false, 0 : : +- ReusedExchange [cr_item_sk#30, cr_order_number#29, cr_return_quantity#24, cr_return_amount#26], Exchange hashpartitioning(cr_order_number#29, cr_item_sk#30, 5) : +- *(61) Project [d_year#11, i_brand_id#17, i_class_id#18, i_category_id#19, i_manufact_id#20, (ss_quantity#35 - coalesce(sr_return_quantity#36, 0)) AS sales_cnt#37, CheckOverflow((promote_precision(cast(ss_ext_sales_price#38 as decimal(8,2))) - promote_precision(cast(coalesce(sr_return_amt#39, 0.00) as decimal(8,2)))), DecimalType(8,2)) AS sales_amt#40] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q75/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q75/simplified.txt index fe195740..636f95ad 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q75/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q75/simplified.txt @@ -65,7 +65,7 @@ TakeOrderedAndProject [curr_yr_cnt,i_brand_id,i_category_id,i_class_id,i_manufac WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Sort [cr_item_sk,cr_order_number] InputAdapter @@ -208,7 +208,7 @@ TakeOrderedAndProject [curr_yr_cnt,i_brand_id,i_category_id,i_class_id,i_manufac WholeStageCodegen Project [d_date_sk,d_year] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] WholeStageCodegen Sort [cr_item_sk,cr_order_number] InputAdapter diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q78/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q78/explain.txt index e78bfb3f..2385489c 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q78/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q78/explain.txt @@ -1,6 +1,6 @@ == Physical Plan == TakeOrderedAndProject(limit=100, orderBy=[ratio#1 ASC NULLS FIRST,ss_qty#2 DESC NULLS LAST,ss_wc#3 DESC NULLS LAST,ss_sp#4 DESC NULLS LAST,other_chan_qty#5 ASC NULLS FIRST,other_chan_wholesale_cost#6 ASC NULLS FIRST,other_chan_sales_price#7 ASC NULLS FIRST,round((cast(ss_qty#2 as double) / cast(coalesce((ws_qty#8 + cs_qty#9), 1) as double)), 2) ASC NULLS FIRST], output=[ratio#1,store_qty#10,store_wholesale_cost#11,store_sales_price#12,other_chan_qty#5,other_chan_wholesale_cost#6,other_chan_sales_price#7]) -+- *(35) Project [round((cast(ss_qty#2 as double) / cast(coalesce((ws_qty#8 + cs_qty#9), 1) as double)), 2) AS ratio#1, ss_qty#2 AS store_qty#10, ss_wc#3 AS store_wholesale_cost#11, ss_sp#4 AS store_sales_price#12, (coalesce(ws_qty#8, 0) + coalesce(cs_qty#9, 0)) AS other_chan_qty#5, CheckOverflow((promote_precision(cast(coalesce(ws_wc#13, 0.00) as decimal(18,2))) + promote_precision(cast(coalesce(cs_wc#14, 0.00) as decimal(18,2)))), DecimalType(18,2)) AS other_chan_wholesale_cost#6, CheckOverflow((promote_precision(cast(coalesce(ws_sp#15, 0.00) as decimal(18,2))) + promote_precision(cast(coalesce(cs_sp#16, 0.00) as decimal(18,2)))), DecimalType(18,2)) AS other_chan_sales_price#7, ss_wc#3, ws_qty#8, ss_qty#2, cs_qty#9, ss_sp#4] ++- *(35) Project [round((cast(ss_qty#2 as double) / cast(coalesce((ws_qty#8 + cs_qty#9), 1) as double)), 2) AS ratio#1, ss_qty#2 AS store_qty#10, ss_wc#3 AS store_wholesale_cost#11, ss_sp#4 AS store_sales_price#12, (coalesce(ws_qty#8, 0) + coalesce(cs_qty#9, 0)) AS other_chan_qty#5, CheckOverflow((promote_precision(cast(coalesce(ws_wc#13, 0.00) as decimal(18,2))) + promote_precision(cast(coalesce(cs_wc#14, 0.00) as decimal(18,2)))), DecimalType(18,2)) AS other_chan_wholesale_cost#6, CheckOverflow((promote_precision(cast(coalesce(ws_sp#15, 0.00) as decimal(18,2))) + promote_precision(cast(coalesce(cs_sp#16, 0.00) as decimal(18,2)))), DecimalType(18,2)) AS other_chan_sales_price#7, ss_qty#2, ss_sp#4, ss_wc#3, ws_qty#8, cs_qty#9] +- *(35) SortMergeJoin [ss_sold_year#17, ss_item_sk#18, ss_customer_sk#19], [cs_sold_year#20, cs_item_sk#21, cs_customer_sk#22], Inner :- *(23) Project [ss_sold_year#17, ss_item_sk#18, ss_customer_sk#19, ss_qty#2, ss_wc#3, ss_sp#4, ws_qty#8, ws_wc#13, ws_sp#15] : +- *(23) SortMergeJoin [ss_sold_year#17, ss_item_sk#18, ss_customer_sk#19], [ws_sold_year#23, ws_item_sk#24, ws_customer_sk#25], Inner @@ -30,7 +30,7 @@ TakeOrderedAndProject(limit=100, orderBy=[ratio#1 ASC NULLS FIRST,ss_qty#2 DESC : : +- Exchange hashpartitioning(d_date_sk#31, 5) : : +- *(7) Project [d_date_sk#31, d_year#26] : : +- *(7) Filter ((isnotnull(d_year#26) && (d_year#26 = 2000)) && isnotnull(d_date_sk#31)) - : : +- *(7) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#31,d_year#26] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct + : : +- *(7) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#31,d_year#26] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct : +- *(22) Sort [ws_sold_year#23 ASC NULLS FIRST, ws_item_sk#24 ASC NULLS FIRST, ws_customer_sk#25 ASC NULLS FIRST], false, 0 : +- Exchange hashpartitioning(ws_sold_year#23, ws_item_sk#24, ws_customer_sk#25, 5) : +- *(21) Filter (coalesce(ws_qty#8, 0) > 0) @@ -47,8 +47,8 @@ TakeOrderedAndProject(limit=100, orderBy=[ratio#1 ASC NULLS FIRST,ss_qty#2 DESC : : :- *(13) Sort [cast(ws_order_number#41 as bigint) ASC NULLS FIRST, cast(ws_item_sk#24 as bigint) ASC NULLS FIRST], false, 0 : : : +- Exchange hashpartitioning(cast(ws_order_number#41 as bigint), cast(ws_item_sk#24 as bigint), 5) : : : +- *(12) Project [ws_sold_date_sk#39, ws_item_sk#24, ws_bill_customer_sk#35, ws_order_number#41, ws_quantity#36, ws_wholesale_cost#37, ws_sales_price#38] - : : : +- *(12) Filter ((isnotnull(ws_sold_date_sk#39) && isnotnull(ws_bill_customer_sk#35)) && isnotnull(ws_item_sk#24)) - : : : +- *(12) FileScan Hyperspace(Type: CI, Name: JoinIndex37-index-9-ws_sold_date_sk-21, LogVersion: 0) default.web_sales[ws_sold_date_sk#39,ws_item_sk#24,ws_bill_customer_sk#35,ws_order_number#41,ws_quantity#36,ws_wholesale_cost#37,ws_sales_price#38] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(ws_sold_date_sk), IsNotNull(ws_bill_customer_sk), IsNotNull(ws_item_sk)], ReadSchema: struct + : : : : +- *(3) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#28,d_year#29] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct : : : +- *(8) Sort [ca_address_sk#18 ASC NULLS FIRST], false, 0 : : : +- Exchange hashpartitioning(ca_address_sk#18, 5) : : : +- *(7) Project [ca_address_sk#18, ca_state#11] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q81/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q81/simplified.txt index e87f9119..15782c74 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q81/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q81/simplified.txt @@ -57,7 +57,7 @@ TakeOrderedAndProject [c_customer_id,c_first_name,c_last_name,c_salutation,ca_ci WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [ca_address_sk] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q85/explain.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q85/explain.txt index 760ce6b2..026e79dc 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q85/explain.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q85/explain.txt @@ -63,7 +63,7 @@ TakeOrderedAndProject(limit=100, orderBy=[substring(r_reason_desc, 1, 20)#1 ASC : +- Exchange hashpartitioning(d_date_sk#13, 5) : +- *(23) Project [d_date_sk#13] : +- *(23) Filter ((isnotnull(d_year#34) && (d_year#34 = 2000)) && isnotnull(d_date_sk#13)) - : +- *(23) FileScan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim[d_date_sk#13,d_year#34] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct + : +- *(23) FileScan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim[d_date_sk#13,d_year#34] Batched: true, Format: Parquet, Location: InMemoryFileIndex[], PartitionFilters: [], PushedFilters: [IsNotNull(d_year), EqualTo(d_year,2000), IsNotNull(d_date_sk)], ReadSchema: struct +- *(28) Sort [cast(r_reason_sk#11 as bigint) ASC NULLS FIRST], false, 0 +- Exchange hashpartitioning(cast(r_reason_sk#11 as bigint), 5) +- *(27) Project [r_reason_sk#11, r_reason_desc#6] diff --git a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q85/simplified.txt b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q85/simplified.txt index ea3b7c18..337db2d3 100644 --- a/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q85/simplified.txt +++ b/src/test/resources/tpcds/hyperspace/approved-plans-v1_4/q85/simplified.txt @@ -117,7 +117,7 @@ TakeOrderedAndProject [aggOrder,avg(wr_fee),avg(wr_refunded_cash),avg(ws_quantit WholeStageCodegen Project [d_date_sk] Filter [d_date_sk,d_year] - Scan Hyperspace(Type: CI, Name: dtindex, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] + Scan Hyperspace(Type: CI, Name: FilterIndex04-index-11-d_year-5, LogVersion: 0) default.date_dim [d_date_sk,d_year] [d_date_sk,d_year] InputAdapter WholeStageCodegen Sort [r_reason_sk] diff --git a/src/test/scala/com/microsoft/hyperspace/goldstandard/TPCDS_Hyperspace.scala b/src/test/scala/com/microsoft/hyperspace/goldstandard/TPCDS_Hyperspace.scala index 466964f7..ebeee393 100644 --- a/src/test/scala/com/microsoft/hyperspace/goldstandard/TPCDS_Hyperspace.scala +++ b/src/test/scala/com/microsoft/hyperspace/goldstandard/TPCDS_Hyperspace.scala @@ -43,8 +43,6 @@ class TPCDS_Hyperspace extends PlanStabilitySuite { // scalastyle:off filelinelengthchecker // TODO: Read indexes from a file. val indexes = Seq( - "dtindex;date_dim;d_date_sk;d_year", - "ssIndex;store_sales;ss_sold_date_sk;ss_customer_sk", "JoinIndex00-index-33-inv_item_sk-3;inventory;inv_item_sk;inv_date_sk,inv_warehouse_sk,inv_quantity_on_hand", "JoinIndex01-index-34-inv_date_sk-3;inventory;inv_date_sk;inv_warehouse_sk,inv_quantity_on_hand,inv_item_sk", "JoinIndex02-index-42-inv_warehouse_sk-3;inventory;inv_warehouse_sk;inv_date_sk,inv_quantity_on_hand,inv_item_sk",