From 57d535b91b4ff4afbe1c319d094fbc483ed2e429 Mon Sep 17 00:00:00 2001 From: morrySnow Date: Mon, 13 Nov 2023 16:35:03 +0800 Subject: [PATCH] [fix](Nereids) column pruning under union broken unexpectedly --- .../nereids/rules/rewrite/ColumnPruning.java | 3 - .../shape/query14.out | 63 ++++---- .../shape/query23.out | 68 +++++---- .../shape/query33.out | 135 ++++++++++-------- .../shape/query5.out | 80 ++++++----- .../shape/query56.out | 66 +++++---- .../shape/query60.out | 111 ++++++++------ .../shape/query66.out | 66 +++++---- .../shape/query74.out | 27 ++-- .../shape/query76.out | 33 +++-- .../shape/query77.out | 87 ++++++----- .../shape/query80.out | 125 ++++++++++------ .../shape/query14.out | 48 ++++--- .../shape/query23.out | 46 +++--- .../shape/query33.out | 132 +++++++++-------- .../shape/query5.out | 80 ++++++----- .../shape/query56.out | 66 +++++---- .../shape/query60.out | 111 ++++++++------ .../shape/query66.out | 68 +++++---- .../shape/query74.out | 27 ++-- .../shape/query76.out | 50 ++++--- .../shape/query77.out | 87 ++++++----- .../shape/query80.out | 121 ++++++++++------ .../rf/ds_rf33.groovy | 2 +- .../rf/ds_rf5.groovy | 2 +- .../rf/ds_rf60.groovy | 2 +- .../rf/ds_rf80.groovy | 2 +- 27 files changed, 1031 insertions(+), 677 deletions(-) diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/ColumnPruning.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/ColumnPruning.java index 32e9cf64b67cb6..dcb330cd28e1a2 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/ColumnPruning.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/ColumnPruning.java @@ -117,9 +117,6 @@ public Plan visitLogicalUnion(LogicalUnion union, PruneContext context) { } LogicalUnion prunedOutputUnion = pruneOutput(union, union.getOutputs(), union::pruneOutputs, context); - if (prunedOutputUnion == union) { - return union; - } // start prune children of union List originOutput = union.getOutput(); diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query14.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query14.out index b8263da7abf8a6..84aba63dbccb9d 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query14.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query14.out @@ -68,24 +68,27 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) --------------------PhysicalProject ----------------------PhysicalOlapScan[store_sales] --------------------PhysicalDistribute -----------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) -------------------------PhysicalOlapScan[date_dim] +----------------------PhysicalProject +------------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) +--------------------------PhysicalOlapScan[date_dim] --------------PhysicalDistribute ----------------PhysicalProject ------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() --------------------PhysicalProject ----------------------PhysicalOlapScan[catalog_sales] --------------------PhysicalDistribute -----------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) -------------------------PhysicalOlapScan[date_dim] +----------------------PhysicalProject +------------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) +--------------------------PhysicalOlapScan[date_dim] --------------PhysicalDistribute ----------------PhysicalProject ------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() --------------------PhysicalProject ----------------------PhysicalOlapScan[web_sales] --------------------PhysicalDistribute -----------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) -------------------------PhysicalOlapScan[date_dim] +----------------------PhysicalProject +------------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) +--------------------------PhysicalOlapScan[date_dim] ----PhysicalResultSink ------PhysicalTopN[MERGE_SORT] --------PhysicalDistribute @@ -107,14 +110,17 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ----------------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((store_sales.ss_item_sk = cross_items.ss_item_sk))otherCondition=() ------------------------------------------PhysicalDistribute --------------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------------PhysicalOlapScan[store_sales] +----------------------------------------------PhysicalProject +------------------------------------------------PhysicalOlapScan[store_sales] ----------------------------------------------PhysicalDistribute -------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2001)) ---------------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------------------PhysicalProject +--------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2001)) +----------------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------------PhysicalDistribute --------------------------------------------PhysicalCteConsumer ( cteId=CTEId#0 ) ----------------------------------------PhysicalDistribute -------------------------------------------PhysicalOlapScan[item] +------------------------------------------PhysicalProject +--------------------------------------------PhysicalOlapScan[item] ----------------------------PhysicalDistribute ------------------------------PhysicalAssertNumRows --------------------------------PhysicalDistribute @@ -130,14 +136,17 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ----------------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((catalog_sales.cs_item_sk = cross_items.ss_item_sk))otherCondition=() ------------------------------------------PhysicalDistribute --------------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------------------PhysicalProject +------------------------------------------------PhysicalOlapScan[catalog_sales] ----------------------------------------------PhysicalDistribute -------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2001)) ---------------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------------------PhysicalProject +--------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2001)) +----------------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------------PhysicalDistribute --------------------------------------------PhysicalCteConsumer ( cteId=CTEId#0 ) ----------------------------------------PhysicalDistribute -------------------------------------------PhysicalOlapScan[item] +------------------------------------------PhysicalProject +--------------------------------------------PhysicalOlapScan[item] ----------------------------PhysicalDistribute ------------------------------PhysicalAssertNumRows --------------------------------PhysicalDistribute @@ -153,14 +162,17 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ----------------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((web_sales.ws_item_sk = cross_items.ss_item_sk))otherCondition=() ------------------------------------------PhysicalDistribute --------------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------------------PhysicalProject +------------------------------------------------PhysicalOlapScan[web_sales] ----------------------------------------------PhysicalDistribute -------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2001)) ---------------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------------------PhysicalProject +--------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2001)) +----------------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------------PhysicalDistribute --------------------------------------------PhysicalCteConsumer ( cteId=CTEId#0 ) ----------------------------------------PhysicalDistribute -------------------------------------------PhysicalOlapScan[item] +------------------------------------------PhysicalProject +--------------------------------------------PhysicalOlapScan[item] ----------------------------PhysicalDistribute ------------------------------PhysicalAssertNumRows --------------------------------PhysicalDistribute @@ -235,24 +247,27 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) --------------------PhysicalProject ----------------------PhysicalOlapScan[store_sales] --------------------PhysicalDistribute -----------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) -------------------------PhysicalOlapScan[date_dim] +----------------------PhysicalProject +------------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) +--------------------------PhysicalOlapScan[date_dim] --------------PhysicalDistribute ----------------PhysicalProject ------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() --------------------PhysicalProject ----------------------PhysicalOlapScan[catalog_sales] --------------------PhysicalDistribute -----------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) -------------------------PhysicalOlapScan[date_dim] +----------------------PhysicalProject +------------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) +--------------------------PhysicalOlapScan[date_dim] --------------PhysicalDistribute ----------------PhysicalProject ------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() --------------------PhysicalProject ----------------------PhysicalOlapScan[web_sales] --------------------PhysicalDistribute -----------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) -------------------------PhysicalOlapScan[date_dim] +----------------------PhysicalProject +------------------------filter((date_dim.d_year <= 2001) and (date_dim.d_year >= 1999)) +--------------------------PhysicalOlapScan[date_dim] ----PhysicalResultSink ------PhysicalTopN[MERGE_SORT] --------PhysicalDistribute diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query23.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query23.out index 96102c3276f762..89c2172fdba539 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query23.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query23.out @@ -66,32 +66,38 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ------------------------PhysicalProject --------------------------PhysicalCteConsumer ( cteId=CTEId#0 ) ----------------------PhysicalDistribute -------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((catalog_sales.cs_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() ---------------------------PhysicalDistribute -----------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------------PhysicalOlapScan[catalog_sales] -------------------------------PhysicalDistribute ---------------------------------filter((date_dim.d_moy = 7) and (date_dim.d_year = 2000)) -----------------------------------PhysicalOlapScan[date_dim] ---------------------------PhysicalDistribute -----------------------------PhysicalProject -------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) +------------------------PhysicalProject +--------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((catalog_sales.cs_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() +----------------------------PhysicalDistribute +------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------PhysicalProject +----------------------------------PhysicalOlapScan[catalog_sales] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((date_dim.d_moy = 7) and (date_dim.d_year = 2000)) +--------------------------------------PhysicalOlapScan[date_dim] +----------------------------PhysicalDistribute +------------------------------PhysicalProject +--------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) ------------------PhysicalProject --------------------hashJoin[RIGHT_SEMI_JOIN] hashCondition=((web_sales.ws_item_sk = frequent_ss_items.item_sk))otherCondition=() ----------------------PhysicalDistribute ------------------------PhysicalProject --------------------------PhysicalCteConsumer ( cteId=CTEId#0 ) ----------------------PhysicalDistribute -------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((web_sales.ws_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() ---------------------------PhysicalDistribute -----------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------------PhysicalOlapScan[web_sales] -------------------------------PhysicalDistribute ---------------------------------filter((date_dim.d_moy = 7) and (date_dim.d_year = 2000)) -----------------------------------PhysicalOlapScan[date_dim] ---------------------------PhysicalDistribute -----------------------------PhysicalProject -------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) +------------------------PhysicalProject +--------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((web_sales.ws_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() +----------------------------PhysicalDistribute +------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------PhysicalProject +----------------------------------PhysicalOlapScan[web_sales] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((date_dim.d_moy = 7) and (date_dim.d_year = 2000)) +--------------------------------------PhysicalOlapScan[date_dim] +----------------------------PhysicalDistribute +------------------------------PhysicalProject +--------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) -- !ds_shape_23_2 -- PhysicalCteAnchor ( cteId=CTEId#0 ) @@ -165,15 +171,18 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ----------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((catalog_sales.cs_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() ------------------------------PhysicalDistribute --------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[catalog_sales] ----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 7) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------filter((date_dim.d_moy = 7) and (date_dim.d_year = 2000)) +----------------------------------------PhysicalOlapScan[date_dim] ------------------------------PhysicalDistribute --------------------------------PhysicalProject ----------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) ----------------------------PhysicalDistribute -------------------------------PhysicalOlapScan[customer] +------------------------------PhysicalProject +--------------------------------PhysicalOlapScan[customer] --------------hashAgg[GLOBAL] ----------------PhysicalDistribute ------------------hashAgg[LOCAL] @@ -185,14 +194,17 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ------------------------PhysicalDistribute --------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_bill_customer_sk = customer.c_customer_sk))otherCondition=() ----------------------------PhysicalDistribute -------------------------------PhysicalOlapScan[customer] +------------------------------PhysicalProject +--------------------------------PhysicalOlapScan[customer] ----------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((web_sales.ws_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() ------------------------------PhysicalDistribute --------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[web_sales] +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[web_sales] ----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 7) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------filter((date_dim.d_moy = 7) and (date_dim.d_year = 2000)) +----------------------------------------PhysicalOlapScan[date_dim] ------------------------------PhysicalDistribute --------------------------------PhysicalProject ----------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query33.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query33.out index 6995aed8d503c1..76b5fbc9efdf35 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query33.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query33.out @@ -9,73 +9,96 @@ PhysicalResultSink ------------hashAgg[LOCAL] --------------PhysicalUnion ----------------PhysicalProject -------------------hashJoin[RIGHT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +------------------hashAgg[GLOBAL] --------------------PhysicalDistribute -----------------------PhysicalProject -------------------------filter((item.i_category = 'Books')) ---------------------------PhysicalOlapScan[item] ---------------------hashAgg[GLOBAL] -----------------------PhysicalDistribute -------------------------hashAgg[LOCAL] ---------------------------PhysicalProject -----------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() -------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_addr_sk = customer_address.ca_address_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[store_sales] +----------------------hashAgg[LOCAL] +------------------------PhysicalProject +--------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() +----------------------------PhysicalDistribute +------------------------------PhysicalProject +--------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2001)) ---------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2001)) +----------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------PhysicalDistribute +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] --------------------------------PhysicalDistribute -----------------------------------filter((customer_address.ca_gmt_offset = -5.00)) -------------------------------------PhysicalOlapScan[customer_address] -------------------------------PhysicalDistribute ---------------------------------PhysicalOlapScan[item] +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Books')) +--------------------------------------PhysicalOlapScan[item] ----------------PhysicalProject -------------------hashJoin[RIGHT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +------------------hashAgg[GLOBAL] --------------------PhysicalDistribute -----------------------PhysicalProject -------------------------filter((item.i_category = 'Books')) ---------------------------PhysicalOlapScan[item] ---------------------hashAgg[GLOBAL] -----------------------PhysicalDistribute -------------------------hashAgg[LOCAL] ---------------------------PhysicalProject -----------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() -------------------------------PhysicalDistribute +----------------------hashAgg[LOCAL] +------------------------PhysicalProject +--------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() +----------------------------PhysicalDistribute +------------------------------PhysicalProject --------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------------PhysicalDistribute -------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[catalog_sales] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2001)) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2001)) +----------------------------------------------PhysicalOlapScan[date_dim] ----------------------------------PhysicalDistribute -------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) ---------------------------------------PhysicalOlapScan[customer_address] -------------------------------PhysicalDistribute ---------------------------------PhysicalOlapScan[item] +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Books')) +--------------------------------------PhysicalOlapScan[item] ----------------PhysicalProject -------------------hashJoin[RIGHT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +------------------hashAgg[GLOBAL] --------------------PhysicalDistribute -----------------------PhysicalProject -------------------------filter((item.i_category = 'Books')) ---------------------------PhysicalOlapScan[item] ---------------------hashAgg[GLOBAL] -----------------------PhysicalDistribute -------------------------hashAgg[LOCAL] ---------------------------PhysicalProject -----------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() -------------------------------PhysicalDistribute +----------------------hashAgg[LOCAL] +------------------------PhysicalProject +--------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() +----------------------------PhysicalDistribute +------------------------------PhysicalProject --------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------------PhysicalDistribute -------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[web_sales] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2001)) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2001)) +----------------------------------------------PhysicalOlapScan[date_dim] ----------------------------------PhysicalDistribute -------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) ---------------------------------------PhysicalOlapScan[customer_address] -------------------------------PhysicalDistribute ---------------------------------PhysicalOlapScan[item] +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Books')) +--------------------------------------PhysicalOlapScan[item] diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query5.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query5.out index d495010b279446..2f84377c34bb21 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query5.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query5.out @@ -16,57 +16,69 @@ PhysicalResultSink --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject ------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.store_sk = store.s_store_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalUnion +--------------------------------PhysicalProject +----------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------PhysicalUnion +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_sales] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_returns] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[store_sales] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[store_returns] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) ---------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) +------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute -----------------------------------PhysicalOlapScan[store] +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[store] --------------------PhysicalProject ----------------------hashAgg[GLOBAL] ------------------------PhysicalDistribute --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject ------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.page_sk = catalog_page.cp_catalog_page_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalUnion -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[catalog_sales] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[catalog_returns] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) ---------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute -----------------------------------PhysicalOlapScan[catalog_page] +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------------PhysicalUnion +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------PhysicalOlapScan[catalog_returns] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) +--------------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[catalog_page] --------------------PhysicalProject ----------------------hashAgg[GLOBAL] ------------------------PhysicalDistribute --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject ------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.wsr_web_site_sk = web_site.web_site_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalUnion -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[web_sales] +--------------------------------PhysicalProject +----------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------PhysicalUnion +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_sales] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_item_sk = web_sales.ws_item_sk) and (web_returns.wr_order_number = web_sales.ws_order_number))otherCondition=() +--------------------------------------------PhysicalProject +----------------------------------------------PhysicalOlapScan[web_sales] +--------------------------------------------PhysicalProject +----------------------------------------------PhysicalOlapScan[web_returns] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject -----------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_item_sk = web_sales.ws_item_sk) and (web_returns.wr_order_number = web_sales.ws_order_number))otherCondition=() -------------------------------------------PhysicalOlapScan[web_sales] -------------------------------------------PhysicalOlapScan[web_returns] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) ---------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) +------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute -----------------------------------PhysicalOlapScan[web_site] +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[web_site] diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query56.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query56.out index bcd9be985e5b8c..93d4f8ffcc331d 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query56.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query56.out @@ -16,21 +16,27 @@ PhysicalResultSink --------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------PhysicalDistribute ------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[store_sales] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalProject +----------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------PhysicalProject +--------------------------------------PhysicalOlapScan[store_sales] +------------------------------------PhysicalDistribute +--------------------------------------PhysicalProject +----------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2000)) +------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute ----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() -------------------------------------PhysicalOlapScan[item] +------------------------------------PhysicalDistribute +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[item] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject ----------------------------------------filter(i_color IN ('orchid', 'pink', 'powder')) ------------------------------------------PhysicalOlapScan[item] ----------------------------PhysicalDistribute -------------------------------filter((customer_address.ca_gmt_offset = -6.00)) ---------------------------------PhysicalOlapScan[customer_address] +------------------------------PhysicalProject +--------------------------------filter((customer_address.ca_gmt_offset = -6.00)) +----------------------------------PhysicalOlapScan[customer_address] ----------------PhysicalProject ------------------hashAgg[GLOBAL] --------------------PhysicalDistribute @@ -39,39 +45,51 @@ PhysicalResultSink --------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------PhysicalDistribute ------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[catalog_sales] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalProject +----------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------PhysicalProject +--------------------------------------PhysicalOlapScan[catalog_sales] +------------------------------------PhysicalDistribute +--------------------------------------PhysicalProject +----------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2000)) +------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute ----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() -------------------------------------PhysicalOlapScan[item] +------------------------------------PhysicalDistribute +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[item] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject ----------------------------------------filter(i_color IN ('orchid', 'pink', 'powder')) ------------------------------------------PhysicalOlapScan[item] ----------------------------PhysicalDistribute -------------------------------filter((customer_address.ca_gmt_offset = -6.00)) ---------------------------------PhysicalOlapScan[customer_address] +------------------------------PhysicalProject +--------------------------------filter((customer_address.ca_gmt_offset = -6.00)) +----------------------------------PhysicalOlapScan[customer_address] ----------------PhysicalProject ------------------hashAgg[GLOBAL] --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject --------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() -----------------------------filter((customer_address.ca_gmt_offset = -6.00)) -------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalProject +------------------------------filter((customer_address.ca_gmt_offset = -6.00)) +--------------------------------PhysicalOlapScan[customer_address] ----------------------------PhysicalDistribute ------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[web_sales] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalProject +----------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------PhysicalProject +--------------------------------------PhysicalOlapScan[web_sales] +------------------------------------PhysicalDistribute +--------------------------------------PhysicalProject +----------------------------------------filter((date_dim.d_moy = 3) and (date_dim.d_year = 2000)) +------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute ----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() -------------------------------------PhysicalOlapScan[item] +------------------------------------PhysicalDistribute +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[item] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject ----------------------------------------filter(i_color IN ('orchid', 'pink', 'powder')) diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query60.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query60.out index 508c0607d9b726..88cc814f158589 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query60.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query60.out @@ -13,71 +13,92 @@ PhysicalResultSink --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject ---------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_addr_sk = customer_address.ca_address_sk))otherCondition=() +--------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ----------------------------PhysicalDistribute -------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[store_sales] +------------------------------PhysicalProject +--------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 10) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 10) and (date_dim.d_year = 2000)) +----------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------PhysicalDistribute +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] --------------------------------PhysicalDistribute -----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() -------------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Jewelry')) --------------------------------------PhysicalOlapScan[item] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------filter((item.i_category = 'Jewelry')) -------------------------------------------PhysicalOlapScan[item] -----------------------------PhysicalDistribute -------------------------------filter((customer_address.ca_gmt_offset = -5.00)) ---------------------------------PhysicalOlapScan[customer_address] ----------------PhysicalProject ------------------hashAgg[GLOBAL] --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject ---------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() +--------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() ----------------------------PhysicalDistribute -------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[catalog_sales] +------------------------------PhysicalProject +--------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() +----------------------------------PhysicalDistribute +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 10) and (date_dim.d_year = 2000)) +----------------------------------------------PhysicalOlapScan[date_dim] ----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 10) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() --------------------------------PhysicalDistribute -----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() -------------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Jewelry')) --------------------------------------PhysicalOlapScan[item] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------filter((item.i_category = 'Jewelry')) -------------------------------------------PhysicalOlapScan[item] -----------------------------PhysicalDistribute -------------------------------filter((customer_address.ca_gmt_offset = -5.00)) ---------------------------------PhysicalOlapScan[customer_address] ----------------PhysicalProject ------------------hashAgg[GLOBAL] --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject ---------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() +--------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ----------------------------PhysicalDistribute -------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[web_sales] +------------------------------PhysicalProject +--------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() +----------------------------------PhysicalDistribute +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 10) and (date_dim.d_year = 2000)) +----------------------------------------------PhysicalOlapScan[date_dim] ----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 10) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] --------------------------------PhysicalDistribute -----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() -------------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Jewelry')) --------------------------------------PhysicalOlapScan[item] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------filter((item.i_category = 'Jewelry')) -------------------------------------------PhysicalOlapScan[item] -----------------------------PhysicalDistribute -------------------------------filter((customer_address.ca_gmt_offset = -5.00)) ---------------------------------PhysicalOlapScan[customer_address] diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query66.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query66.out index 4ee06f08016ba7..d5bb1b9acebf52 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query66.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query66.out @@ -14,40 +14,54 @@ PhysicalResultSink ----------------------hashAgg[LOCAL] ------------------------PhysicalProject --------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_warehouse_sk = warehouse.w_warehouse_sk))otherCondition=() -----------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_time_sk = time_dim.t_time_sk))otherCondition=() -------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_ship_mode_sk = ship_mode.sm_ship_mode_sk))otherCondition=() -----------------------------------PhysicalOlapScan[web_sales] -----------------------------------PhysicalDistribute -------------------------------------filter(sm_carrier IN ('BOXBUNDLES', 'ORIENTAL')) ---------------------------------------PhysicalOlapScan[ship_mode] +----------------------------PhysicalProject +------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_time_sk = time_dim.t_time_sk))otherCondition=() +--------------------------------PhysicalProject +----------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_ship_mode_sk = ship_mode.sm_ship_mode_sk))otherCondition=() +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[web_sales] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------filter(sm_carrier IN ('BOXBUNDLES', 'ORIENTAL')) +--------------------------------------------PhysicalOlapScan[ship_mode] +------------------------------------PhysicalDistribute +--------------------------------------PhysicalProject +----------------------------------------filter((date_dim.d_year = 2001)) +------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute -----------------------------------filter((date_dim.d_year = 2001)) -------------------------------------PhysicalOlapScan[date_dim] -------------------------------PhysicalDistribute ---------------------------------filter((cast(t_time as BIGINT) <= 71770) and (time_dim.t_time >= 42970)) -----------------------------------PhysicalOlapScan[time_dim] +----------------------------------PhysicalProject +------------------------------------filter((cast(t_time as BIGINT) <= 71770) and (time_dim.t_time >= 42970)) +--------------------------------------PhysicalOlapScan[time_dim] ----------------------------PhysicalDistribute -------------------------------PhysicalOlapScan[warehouse] +------------------------------PhysicalProject +--------------------------------PhysicalOlapScan[warehouse] ----------------PhysicalProject ------------------hashAgg[GLOBAL] --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject --------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_warehouse_sk = warehouse.w_warehouse_sk))otherCondition=() -----------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_time_sk = time_dim.t_time_sk))otherCondition=() -------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_ship_mode_sk = ship_mode.sm_ship_mode_sk))otherCondition=() -----------------------------------PhysicalOlapScan[catalog_sales] -----------------------------------PhysicalDistribute -------------------------------------filter(sm_carrier IN ('BOXBUNDLES', 'ORIENTAL')) ---------------------------------------PhysicalOlapScan[ship_mode] +----------------------------PhysicalProject +------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_time_sk = time_dim.t_time_sk))otherCondition=() +--------------------------------PhysicalProject +----------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_ship_mode_sk = ship_mode.sm_ship_mode_sk))otherCondition=() +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[catalog_sales] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------filter(sm_carrier IN ('BOXBUNDLES', 'ORIENTAL')) +--------------------------------------------PhysicalOlapScan[ship_mode] +------------------------------------PhysicalDistribute +--------------------------------------PhysicalProject +----------------------------------------filter((date_dim.d_year = 2001)) +------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute -----------------------------------filter((date_dim.d_year = 2001)) -------------------------------------PhysicalOlapScan[date_dim] -------------------------------PhysicalDistribute ---------------------------------filter((cast(t_time as BIGINT) <= 71770) and (time_dim.t_time >= 42970)) -----------------------------------PhysicalOlapScan[time_dim] +----------------------------------PhysicalProject +------------------------------------filter((cast(t_time as BIGINT) <= 71770) and (time_dim.t_time >= 42970)) +--------------------------------------PhysicalOlapScan[time_dim] ----------------------------PhysicalDistribute -------------------------------PhysicalOlapScan[warehouse] +------------------------------PhysicalProject +--------------------------------PhysicalOlapScan[warehouse] diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query74.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query74.out index d075079ea86339..7c78f983124461 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query74.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query74.out @@ -9,13 +9,17 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ------------hashAgg[LOCAL] --------------PhysicalProject ----------------hashJoin[INNER_JOIN] hashCondition=((customer.c_customer_sk = store_sales.ss_customer_sk))otherCondition=() -------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------PhysicalOlapScan[store_sales] ---------------------PhysicalDistribute -----------------------filter(d_year IN (1999, 2000)) -------------------------PhysicalOlapScan[date_dim] ------------------PhysicalDistribute ---------------------PhysicalOlapScan[customer] +--------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------PhysicalProject +------------------------PhysicalOlapScan[store_sales] +----------------------PhysicalDistribute +------------------------PhysicalProject +--------------------------filter(d_year IN (1999, 2000)) +----------------------------PhysicalOlapScan[date_dim] +------------------PhysicalDistribute +--------------------PhysicalProject +----------------------PhysicalOlapScan[customer] ------PhysicalProject --------hashAgg[GLOBAL] ----------PhysicalDistribute @@ -24,12 +28,15 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ----------------hashJoin[INNER_JOIN] hashCondition=((customer.c_customer_sk = web_sales.ws_bill_customer_sk))otherCondition=() ------------------PhysicalDistribute --------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------PhysicalOlapScan[web_sales] +----------------------PhysicalProject +------------------------PhysicalOlapScan[web_sales] ----------------------PhysicalDistribute -------------------------filter(d_year IN (1999, 2000)) ---------------------------PhysicalOlapScan[date_dim] +------------------------PhysicalProject +--------------------------filter(d_year IN (1999, 2000)) +----------------------------PhysicalOlapScan[date_dim] ------------------PhysicalDistribute ---------------------PhysicalOlapScan[customer] +--------------------PhysicalProject +----------------------PhysicalOlapScan[customer] --PhysicalResultSink ----PhysicalTopN[MERGE_SORT] ------PhysicalDistribute diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query76.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query76.out index e397c8c30ae3e1..d47ee1880bcc1b 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query76.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query76.out @@ -12,30 +12,39 @@ PhysicalResultSink ------------------PhysicalProject --------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ----------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------filter(ss_customer_sk IS NULL) ---------------------------PhysicalOlapScan[store_sales] +------------------------PhysicalProject +--------------------------filter(ss_customer_sk IS NULL) +----------------------------PhysicalOlapScan[store_sales] ------------------------PhysicalDistribute ---------------------------PhysicalOlapScan[date_dim] +--------------------------PhysicalProject +----------------------------PhysicalOlapScan[date_dim] ----------------------PhysicalDistribute -------------------------PhysicalOlapScan[item] +------------------------PhysicalProject +--------------------------PhysicalOlapScan[item] ----------------PhysicalDistribute ------------------PhysicalProject --------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ----------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------filter(ws_promo_sk IS NULL) ---------------------------PhysicalOlapScan[web_sales] +------------------------PhysicalProject +--------------------------filter(ws_promo_sk IS NULL) +----------------------------PhysicalOlapScan[web_sales] ------------------------PhysicalDistribute ---------------------------PhysicalOlapScan[date_dim] +--------------------------PhysicalProject +----------------------------PhysicalOlapScan[date_dim] ----------------------PhysicalDistribute -------------------------PhysicalOlapScan[item] +------------------------PhysicalProject +--------------------------PhysicalOlapScan[item] ----------------PhysicalDistribute ------------------PhysicalProject --------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() ----------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------filter(cs_bill_customer_sk IS NULL) ---------------------------PhysicalOlapScan[catalog_sales] +------------------------PhysicalProject +--------------------------filter(cs_bill_customer_sk IS NULL) +----------------------------PhysicalOlapScan[catalog_sales] ------------------------PhysicalDistribute ---------------------------PhysicalOlapScan[date_dim] +--------------------------PhysicalProject +----------------------------PhysicalOlapScan[date_dim] ----------------------PhysicalDistribute -------------------------PhysicalOlapScan[item] +------------------------PhysicalProject +--------------------------PhysicalOlapScan[item] diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query77.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query77.out index 0c80dfd62aa717..30a6c210ade3ee 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query77.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query77.out @@ -18,26 +18,34 @@ PhysicalResultSink ------------------------------hashAgg[LOCAL] --------------------------------PhysicalProject ----------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_store_sk = store.s_store_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[store_sales] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) +----------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[store] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[store] ------------------------PhysicalProject --------------------------hashAgg[GLOBAL] ----------------------------PhysicalDistribute ------------------------------hashAgg[LOCAL] --------------------------------PhysicalProject ----------------------------------hashJoin[INNER_JOIN] hashCondition=((store_returns.sr_store_sk = store.s_store_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_returns.sr_returned_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[store_returns] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_returns.sr_returned_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_returns] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) +----------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[store] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[store] --------------------PhysicalProject ----------------------NestedLoopJoin[CROSS_JOIN] ------------------------PhysicalProject @@ -46,10 +54,12 @@ PhysicalResultSink ------------------------------hashAgg[LOCAL] --------------------------------PhysicalProject ----------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------------------PhysicalOlapScan[catalog_sales] +------------------------------------PhysicalProject +--------------------------------------PhysicalOlapScan[catalog_sales] ------------------------------------PhysicalDistribute ---------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) -----------------------------------------PhysicalOlapScan[date_dim] +--------------------------------------PhysicalProject +----------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) +------------------------------------------PhysicalOlapScan[date_dim] ------------------------PhysicalDistribute --------------------------PhysicalProject ----------------------------hashAgg[GLOBAL] @@ -57,10 +67,12 @@ PhysicalResultSink --------------------------------hashAgg[LOCAL] ----------------------------------PhysicalProject ------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_returns.cr_returned_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[catalog_returns] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[catalog_returns] --------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) -------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) +--------------------------------------------PhysicalOlapScan[date_dim] --------------------PhysicalProject ----------------------hashJoin[LEFT_OUTER_JOIN] hashCondition=((ws.wp_web_page_sk = wr.wp_web_page_sk))otherCondition=() ------------------------PhysicalProject @@ -69,24 +81,31 @@ PhysicalResultSink ------------------------------hashAgg[LOCAL] --------------------------------PhysicalProject ----------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_web_page_sk = web_page.wp_web_page_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[web_sales] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) +----------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[web_page] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[web_page] ------------------------PhysicalProject ---------------------------hashAgg[GLOBAL] -----------------------------PhysicalDistribute -------------------------------hashAgg[LOCAL] ---------------------------------PhysicalProject -----------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_web_page_sk = web_page.wp_web_page_sk))otherCondition=() +--------------------------hashAgg[LOCAL] +----------------------------PhysicalProject +------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_web_page_sk = web_page.wp_web_page_sk))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject ------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_returned_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[web_returns] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[web_returns] --------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) -------------------------------------------PhysicalOlapScan[date_dim] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[web_page] +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_date <= '2000-09-09') and (date_dim.d_date >= '2000-08-10')) +--------------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[web_page] diff --git a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query80.out b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query80.out index 5ce5de041eb9b1..b9abfd241a34ff 100644 --- a/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query80.out +++ b/regression-test/data/nereids_tpcds_shape_sf1000_p0/shape/query80.out @@ -16,45 +16,67 @@ PhysicalResultSink --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject ------------------------------hashJoin[RIGHT_OUTER_JOIN] hashCondition=((store_sales.ss_item_sk = store_returns.sr_item_sk) and (store_sales.ss_ticket_number = store_returns.sr_ticket_number))otherCondition=() ---------------------------------PhysicalOlapScan[store_returns] ---------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_store_sk = store.s_store_sk))otherCondition=() -----------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_promo_sk = promotion.p_promo_sk))otherCondition=() ---------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------PhysicalOlapScan[store_sales] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[store_returns] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_store_sk = store.s_store_sk))otherCondition=() +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ----------------------------------------PhysicalDistribute -------------------------------------------filter((date_dim.d_date <= '2002-09-13') and (date_dim.d_date >= '2002-08-14')) ---------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------------PhysicalProject +--------------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_promo_sk = promotion.p_promo_sk))otherCondition=() +----------------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------------------PhysicalProject +--------------------------------------------------PhysicalOlapScan[store_sales] +------------------------------------------------PhysicalDistribute +--------------------------------------------------PhysicalProject +----------------------------------------------------filter((date_dim.d_date <= '2002-09-13') and (date_dim.d_date >= '2002-08-14')) +------------------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------------PhysicalDistribute +------------------------------------------------PhysicalProject +--------------------------------------------------filter((promotion.p_channel_tv = 'N')) +----------------------------------------------------PhysicalOlapScan[promotion] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((item.i_current_price > 50.00)) +----------------------------------------------PhysicalOlapScan[item] --------------------------------------PhysicalDistribute -----------------------------------------filter((promotion.p_channel_tv = 'N')) -------------------------------------------PhysicalOlapScan[promotion] -------------------------------------PhysicalDistribute ---------------------------------------filter((item.i_current_price > 50.00)) -----------------------------------------PhysicalOlapScan[item] -----------------------------------PhysicalDistribute -------------------------------------PhysicalOlapScan[store] +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store] --------------------PhysicalProject ----------------------hashAgg[GLOBAL] ------------------------PhysicalDistribute --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject -------------------------------hashJoin[RIGHT_OUTER_JOIN] hashCondition=((catalog_sales.cs_item_sk = catalog_returns.cr_item_sk) and (catalog_sales.cs_order_number = catalog_returns.cr_order_number))otherCondition=() ---------------------------------PhysicalOlapScan[catalog_returns] ---------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_catalog_page_sk = catalog_page.cp_catalog_page_sk))otherCondition=() -----------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_promo_sk = promotion.p_promo_sk))otherCondition=() ---------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------PhysicalOlapScan[catalog_sales] -----------------------------------------PhysicalDistribute -------------------------------------------filter((date_dim.d_date <= '2002-09-13') and (date_dim.d_date >= '2002-08-14')) ---------------------------------------------PhysicalOlapScan[date_dim] ---------------------------------------PhysicalDistribute -----------------------------------------filter((promotion.p_channel_tv = 'N')) -------------------------------------------PhysicalOlapScan[promotion] +------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_catalog_page_sk = catalog_page.cp_catalog_page_sk))otherCondition=() +--------------------------------PhysicalProject +----------------------------------hashJoin[RIGHT_OUTER_JOIN] hashCondition=((catalog_sales.cs_item_sk = catalog_returns.cr_item_sk) and (catalog_sales.cs_order_number = catalog_returns.cr_order_number))otherCondition=() +------------------------------------PhysicalDistribute +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[catalog_returns] ------------------------------------PhysicalDistribute ---------------------------------------filter((item.i_current_price > 50.00)) -----------------------------------------PhysicalOlapScan[item] -----------------------------------PhysicalDistribute +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_promo_sk = promotion.p_promo_sk))otherCondition=() +----------------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------------------PhysicalProject +--------------------------------------------------PhysicalOlapScan[catalog_sales] +------------------------------------------------PhysicalDistribute +--------------------------------------------------PhysicalProject +----------------------------------------------------filter((date_dim.d_date <= '2002-09-13') and (date_dim.d_date >= '2002-08-14')) +------------------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------------PhysicalDistribute +------------------------------------------------PhysicalProject +--------------------------------------------------filter((promotion.p_channel_tv = 'N')) +----------------------------------------------------PhysicalOlapScan[promotion] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((item.i_current_price > 50.00)) +----------------------------------------------PhysicalOlapScan[item] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject ------------------------------------PhysicalOlapScan[catalog_page] --------------------PhysicalProject ----------------------hashAgg[GLOBAL] @@ -62,21 +84,32 @@ PhysicalResultSink --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject ------------------------------hashJoin[RIGHT_OUTER_JOIN] hashCondition=((web_sales.ws_item_sk = web_returns.wr_item_sk) and (web_sales.ws_order_number = web_returns.wr_order_number))otherCondition=() ---------------------------------PhysicalOlapScan[web_returns] ---------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_web_site_sk = web_site.web_site_sk))otherCondition=() -----------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_promo_sk = promotion.p_promo_sk))otherCondition=() ---------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------PhysicalOlapScan[web_sales] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[web_returns] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_web_site_sk = web_site.web_site_sk))otherCondition=() +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ----------------------------------------PhysicalDistribute -------------------------------------------filter((date_dim.d_date <= '2002-09-13') and (date_dim.d_date >= '2002-08-14')) ---------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------------PhysicalProject +--------------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_promo_sk = promotion.p_promo_sk))otherCondition=() +----------------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------------------PhysicalProject +--------------------------------------------------PhysicalOlapScan[web_sales] +------------------------------------------------PhysicalDistribute +--------------------------------------------------PhysicalProject +----------------------------------------------------filter((date_dim.d_date <= '2002-09-13') and (date_dim.d_date >= '2002-08-14')) +------------------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------------PhysicalDistribute +------------------------------------------------PhysicalProject +--------------------------------------------------filter((promotion.p_channel_tv = 'N')) +----------------------------------------------------PhysicalOlapScan[promotion] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((item.i_current_price > 50.00)) +----------------------------------------------PhysicalOlapScan[item] --------------------------------------PhysicalDistribute -----------------------------------------filter((promotion.p_channel_tv = 'N')) -------------------------------------------PhysicalOlapScan[promotion] -------------------------------------PhysicalDistribute ---------------------------------------filter((item.i_current_price > 50.00)) -----------------------------------------PhysicalOlapScan[item] -----------------------------------PhysicalDistribute -------------------------------------PhysicalOlapScan[web_site] +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_site] diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query14.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query14.out index 56a114cf96fc55..ffca3cf5b79087 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query14.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query14.out @@ -70,24 +70,27 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) --------------------PhysicalProject ----------------------PhysicalOlapScan[store_sales] --------------------PhysicalDistribute -----------------------filter((date_dim.d_year <= 2002) and (date_dim.d_year >= 2000)) -------------------------PhysicalOlapScan[date_dim] +----------------------PhysicalProject +------------------------filter((date_dim.d_year <= 2002) and (date_dim.d_year >= 2000)) +--------------------------PhysicalOlapScan[date_dim] --------------PhysicalDistribute ----------------PhysicalProject ------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() --------------------PhysicalProject ----------------------PhysicalOlapScan[catalog_sales] --------------------PhysicalDistribute -----------------------filter((date_dim.d_year <= 2002) and (date_dim.d_year >= 2000)) -------------------------PhysicalOlapScan[date_dim] +----------------------PhysicalProject +------------------------filter((date_dim.d_year <= 2002) and (date_dim.d_year >= 2000)) +--------------------------PhysicalOlapScan[date_dim] --------------PhysicalDistribute ----------------PhysicalProject ------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() --------------------PhysicalProject ----------------------PhysicalOlapScan[web_sales] --------------------PhysicalDistribute -----------------------filter((date_dim.d_year <= 2002) and (date_dim.d_year >= 2000)) -------------------------PhysicalOlapScan[date_dim] +----------------------PhysicalProject +------------------------filter((date_dim.d_year <= 2002) and (date_dim.d_year >= 2000)) +--------------------------PhysicalOlapScan[date_dim] ----PhysicalResultSink ------PhysicalTopN[MERGE_SORT] --------PhysicalDistribute @@ -111,12 +114,15 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ----------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ------------------------------------------PhysicalDistribute --------------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------------PhysicalOlapScan[store_sales] +----------------------------------------------PhysicalProject +------------------------------------------------PhysicalOlapScan[store_sales] ----------------------------------------------PhysicalDistribute -------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2002)) ---------------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------------------PhysicalProject +--------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2002)) +----------------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------------PhysicalDistribute ---------------------------------------------PhysicalOlapScan[item] +--------------------------------------------PhysicalProject +----------------------------------------------PhysicalOlapScan[item] ----------------------------PhysicalDistribute ------------------------------PhysicalAssertNumRows --------------------------------PhysicalDistribute @@ -134,12 +140,15 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ----------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() ------------------------------------------PhysicalDistribute --------------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------------------PhysicalProject +------------------------------------------------PhysicalOlapScan[catalog_sales] ----------------------------------------------PhysicalDistribute -------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2002)) ---------------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------------------PhysicalProject +--------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2002)) +----------------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------------PhysicalDistribute ---------------------------------------------PhysicalOlapScan[item] +--------------------------------------------PhysicalProject +----------------------------------------------PhysicalOlapScan[item] ----------------------------PhysicalDistribute ------------------------------PhysicalAssertNumRows --------------------------------PhysicalDistribute @@ -157,12 +166,15 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ----------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ------------------------------------------PhysicalDistribute --------------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------------------PhysicalProject +------------------------------------------------PhysicalOlapScan[web_sales] ----------------------------------------------PhysicalDistribute -------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2002)) ---------------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------------------PhysicalProject +--------------------------------------------------filter((date_dim.d_moy = 11) and (date_dim.d_year = 2002)) +----------------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------------PhysicalDistribute ---------------------------------------------PhysicalOlapScan[item] +--------------------------------------------PhysicalProject +----------------------------------------------PhysicalOlapScan[item] ----------------------------PhysicalDistribute ------------------------------PhysicalAssertNumRows --------------------------------PhysicalDistribute diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query23.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query23.out index 651f5cde30c9b6..1aaee459c4a47e 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query23.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query23.out @@ -66,30 +66,36 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ------------------------PhysicalProject --------------------------PhysicalCteConsumer ( cteId=CTEId#0 ) ----------------------PhysicalDistribute -------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((catalog_sales.cs_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() ---------------------------PhysicalDistribute -----------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------------PhysicalOlapScan[catalog_sales] -------------------------------PhysicalDistribute ---------------------------------filter((date_dim.d_moy = 5) and (date_dim.d_year = 2000)) -----------------------------------PhysicalOlapScan[date_dim] ---------------------------PhysicalDistribute -----------------------------PhysicalProject -------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) +------------------------PhysicalProject +--------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((catalog_sales.cs_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() +----------------------------PhysicalDistribute +------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------PhysicalProject +----------------------------------PhysicalOlapScan[catalog_sales] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((date_dim.d_moy = 5) and (date_dim.d_year = 2000)) +--------------------------------------PhysicalOlapScan[date_dim] +----------------------------PhysicalDistribute +------------------------------PhysicalProject +--------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) ------------------PhysicalProject --------------------hashJoin[RIGHT_SEMI_JOIN] hashCondition=((web_sales.ws_item_sk = frequent_ss_items.item_sk))otherCondition=() ----------------------PhysicalDistribute ------------------------PhysicalProject --------------------------PhysicalCteConsumer ( cteId=CTEId#0 ) ----------------------PhysicalDistribute -------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((web_sales.ws_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() ---------------------------PhysicalDistribute -----------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------------PhysicalOlapScan[web_sales] -------------------------------PhysicalDistribute ---------------------------------filter((date_dim.d_moy = 5) and (date_dim.d_year = 2000)) -----------------------------------PhysicalOlapScan[date_dim] ---------------------------PhysicalDistribute -----------------------------PhysicalProject -------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) +------------------------PhysicalProject +--------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((web_sales.ws_bill_customer_sk = best_ss_customer.c_customer_sk))otherCondition=() +----------------------------PhysicalDistribute +------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------PhysicalProject +----------------------------------PhysicalOlapScan[web_sales] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((date_dim.d_moy = 5) and (date_dim.d_year = 2000)) +--------------------------------------PhysicalOlapScan[date_dim] +----------------------------PhysicalDistribute +------------------------------PhysicalProject +--------------------------------PhysicalCteConsumer ( cteId=CTEId#2 ) diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query33.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query33.out index ca7f0bf6d7248e..e7aed1c8cfc6fb 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query33.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query33.out @@ -9,73 +9,93 @@ PhysicalResultSink ------------hashAgg[LOCAL] --------------PhysicalUnion ----------------PhysicalProject -------------------hashJoin[RIGHT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +------------------hashAgg[GLOBAL] --------------------PhysicalDistribute -----------------------PhysicalProject -------------------------filter((item.i_category = 'Home')) ---------------------------PhysicalOlapScan[item] ---------------------hashAgg[GLOBAL] -----------------------PhysicalDistribute -------------------------hashAgg[LOCAL] ---------------------------PhysicalProject -----------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() -------------------------------PhysicalDistribute +----------------------hashAgg[LOCAL] +------------------------PhysicalProject +--------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() +----------------------------PhysicalDistribute +------------------------------PhysicalProject --------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_addr_sk = customer_address.ca_address_sk))otherCondition=() -----------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------------------PhysicalOlapScan[store_sales] -------------------------------------PhysicalDistribute ---------------------------------------filter((date_dim.d_moy = 1) and (date_dim.d_year = 2002)) -----------------------------------------PhysicalOlapScan[date_dim] ----------------------------------PhysicalDistribute -------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) ---------------------------------------PhysicalOlapScan[customer_address] -------------------------------PhysicalDistribute ---------------------------------PhysicalOlapScan[item] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 1) and (date_dim.d_year = 2002)) +----------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------PhysicalDistribute +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Home')) +--------------------------------------PhysicalOlapScan[item] ----------------PhysicalProject -------------------hashJoin[RIGHT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +------------------hashAgg[GLOBAL] --------------------PhysicalDistribute -----------------------PhysicalProject -------------------------filter((item.i_category = 'Home')) ---------------------------PhysicalOlapScan[item] ---------------------hashAgg[GLOBAL] -----------------------PhysicalDistribute -------------------------hashAgg[LOCAL] ---------------------------PhysicalProject -----------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() -------------------------------PhysicalDistribute +----------------------hashAgg[LOCAL] +------------------------PhysicalProject +--------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() +----------------------------PhysicalDistribute +------------------------------PhysicalProject --------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------------PhysicalDistribute -------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[catalog_sales] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_moy = 1) and (date_dim.d_year = 2002)) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 1) and (date_dim.d_year = 2002)) +----------------------------------------------PhysicalOlapScan[date_dim] ----------------------------------PhysicalDistribute -------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) ---------------------------------------PhysicalOlapScan[customer_address] -------------------------------PhysicalDistribute ---------------------------------PhysicalOlapScan[item] +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Home')) +--------------------------------------PhysicalOlapScan[item] ----------------PhysicalProject -------------------hashJoin[RIGHT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() ---------------------PhysicalDistribute -----------------------PhysicalProject -------------------------filter((item.i_category = 'Home')) ---------------------------PhysicalOlapScan[item] ---------------------hashAgg[GLOBAL] -----------------------PhysicalDistribute -------------------------hashAgg[LOCAL] ---------------------------PhysicalProject -----------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() +------------------hashAgg[LOCAL] +--------------------PhysicalProject +----------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_manufact_id = item.i_manufact_id))otherCondition=() +------------------------PhysicalDistribute +--------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() +----------------------------PhysicalProject ------------------------------PhysicalOlapScan[item] -------------------------------PhysicalDistribute +----------------------------PhysicalDistribute +------------------------------PhysicalProject --------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------------PhysicalDistribute -------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[web_sales] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_moy = 1) and (date_dim.d_year = 2002)) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 1) and (date_dim.d_year = 2002)) +----------------------------------------------PhysicalOlapScan[date_dim] ----------------------------------PhysicalDistribute -------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) ---------------------------------------PhysicalOlapScan[customer_address] +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -5.00)) +----------------------------------------PhysicalOlapScan[customer_address] +------------------------PhysicalDistribute +--------------------------PhysicalProject +----------------------------filter((item.i_category = 'Home')) +------------------------------PhysicalOlapScan[item] diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query5.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query5.out index d495010b279446..2f84377c34bb21 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query5.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query5.out @@ -16,57 +16,69 @@ PhysicalResultSink --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject ------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.store_sk = store.s_store_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalUnion +--------------------------------PhysicalProject +----------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------PhysicalUnion +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_sales] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_returns] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[store_sales] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[store_returns] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) ---------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) +------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute -----------------------------------PhysicalOlapScan[store] +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[store] --------------------PhysicalProject ----------------------hashAgg[GLOBAL] ------------------------PhysicalDistribute --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject ------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.page_sk = catalog_page.cp_catalog_page_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalUnion -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[catalog_sales] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[catalog_returns] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) ---------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute -----------------------------------PhysicalOlapScan[catalog_page] +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------------PhysicalUnion +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------PhysicalOlapScan[catalog_returns] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) +--------------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[catalog_page] --------------------PhysicalProject ----------------------hashAgg[GLOBAL] ------------------------PhysicalDistribute --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject ------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.wsr_web_site_sk = web_site.web_site_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalUnion -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------PhysicalOlapScan[web_sales] +--------------------------------PhysicalProject +----------------------------------hashJoin[INNER_JOIN] hashCondition=((salesreturns.date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------PhysicalUnion +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_sales] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_item_sk = web_sales.ws_item_sk) and (web_returns.wr_order_number = web_sales.ws_order_number))otherCondition=() +--------------------------------------------PhysicalProject +----------------------------------------------PhysicalOlapScan[web_sales] +--------------------------------------------PhysicalProject +----------------------------------------------PhysicalOlapScan[web_returns] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject -----------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_item_sk = web_sales.ws_item_sk) and (web_returns.wr_order_number = web_sales.ws_order_number))otherCondition=() -------------------------------------------PhysicalOlapScan[web_sales] -------------------------------------------PhysicalOlapScan[web_returns] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) ---------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------filter((date_dim.d_date <= '2000-09-02') and (date_dim.d_date >= '2000-08-19')) +------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute -----------------------------------PhysicalOlapScan[web_site] +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[web_site] diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query56.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query56.out index ecd860221f9214..f93cb183b19a8e 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query56.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query56.out @@ -16,41 +16,53 @@ PhysicalResultSink --------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------PhysicalDistribute ------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[store_sales] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 2) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[store_sales] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_moy = 2) and (date_dim.d_year = 2000)) +--------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute ----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() ------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[item] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[item] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject ----------------------------------------filter(i_color IN ('cyan', 'green', 'powder')) ------------------------------------------PhysicalOlapScan[item] ----------------------------PhysicalDistribute -------------------------------filter((customer_address.ca_gmt_offset = -6.00)) ---------------------------------PhysicalOlapScan[customer_address] +------------------------------PhysicalProject +--------------------------------filter((customer_address.ca_gmt_offset = -6.00)) +----------------------------------PhysicalOlapScan[customer_address] ----------------PhysicalProject ------------------hashAgg[GLOBAL] --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject --------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() -----------------------------filter((customer_address.ca_gmt_offset = -6.00)) -------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalProject +------------------------------filter((customer_address.ca_gmt_offset = -6.00)) +--------------------------------PhysicalOlapScan[customer_address] ----------------------------PhysicalDistribute ------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[catalog_sales] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 2) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[catalog_sales] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_moy = 2) and (date_dim.d_year = 2000)) +--------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute ----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() ------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[item] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[item] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject ----------------------------------------filter(i_color IN ('cyan', 'green', 'powder')) @@ -61,19 +73,25 @@ PhysicalResultSink ----------------------hashAgg[LOCAL] ------------------------PhysicalProject --------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() -----------------------------filter((customer_address.ca_gmt_offset = -6.00)) -------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalProject +------------------------------filter((customer_address.ca_gmt_offset = -6.00)) +--------------------------------PhysicalOlapScan[customer_address] ----------------------------PhysicalDistribute ------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[web_sales] -----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 2) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[web_sales] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_moy = 2) and (date_dim.d_year = 2000)) +--------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute ----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() ------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[item] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[item] ------------------------------------PhysicalDistribute --------------------------------------PhysicalProject ----------------------------------------filter(i_color IN ('cyan', 'green', 'powder')) diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query60.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query60.out index 3da5f55de35d95..d04a8b93990aff 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query60.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query60.out @@ -13,71 +13,92 @@ PhysicalResultSink --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject ---------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_addr_sk = customer_address.ca_address_sk))otherCondition=() +--------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ----------------------------PhysicalDistribute -------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[store_sales] +------------------------------PhysicalProject +--------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_addr_sk = customer_address.ca_address_sk))otherCondition=() ----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 8) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 8) and (date_dim.d_year = 2000)) +----------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------PhysicalDistribute +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -7.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] --------------------------------PhysicalDistribute -----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() -------------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Children')) --------------------------------------PhysicalOlapScan[item] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------filter((item.i_category = 'Children')) -------------------------------------------PhysicalOlapScan[item] -----------------------------PhysicalDistribute -------------------------------filter((customer_address.ca_gmt_offset = -7.00)) ---------------------------------PhysicalOlapScan[customer_address] ----------------PhysicalProject ------------------hashAgg[GLOBAL] --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject ---------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() +--------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() ----------------------------PhysicalDistribute -------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[catalog_sales] +------------------------------PhysicalProject +--------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() +----------------------------------PhysicalDistribute +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 8) and (date_dim.d_year = 2000)) +----------------------------------------------PhysicalOlapScan[date_dim] ----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 8) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -7.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() --------------------------------PhysicalDistribute -----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() -------------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Children')) --------------------------------------PhysicalOlapScan[item] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------filter((item.i_category = 'Children')) -------------------------------------------PhysicalOlapScan[item] -----------------------------PhysicalDistribute -------------------------------filter((customer_address.ca_gmt_offset = -7.00)) ---------------------------------PhysicalOlapScan[customer_address] ----------------PhysicalProject ------------------hashAgg[GLOBAL] --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject ---------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() +--------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ----------------------------PhysicalDistribute -------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------PhysicalOlapScan[web_sales] +------------------------------PhysicalProject +--------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_bill_addr_sk = customer_address.ca_address_sk))otherCondition=() +----------------------------------PhysicalDistribute +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_moy = 8) and (date_dim.d_year = 2000)) +----------------------------------------------PhysicalOlapScan[date_dim] ----------------------------------PhysicalDistribute -------------------------------------filter((date_dim.d_moy = 8) and (date_dim.d_year = 2000)) ---------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------filter((customer_address.ca_gmt_offset = -7.00)) +----------------------------------------PhysicalOlapScan[customer_address] +----------------------------PhysicalDistribute +------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[item] --------------------------------PhysicalDistribute -----------------------------------hashJoin[LEFT_SEMI_JOIN] hashCondition=((item.i_item_id = item.i_item_id))otherCondition=() -------------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((item.i_category = 'Children')) --------------------------------------PhysicalOlapScan[item] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalProject -----------------------------------------filter((item.i_category = 'Children')) -------------------------------------------PhysicalOlapScan[item] -----------------------------PhysicalDistribute -------------------------------filter((customer_address.ca_gmt_offset = -7.00)) ---------------------------------PhysicalOlapScan[customer_address] diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query66.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query66.out index 6491fbfdcbc32e..201886dd2a0f9b 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query66.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query66.out @@ -14,40 +14,56 @@ PhysicalResultSink ----------------------hashAgg[LOCAL] ------------------------PhysicalProject --------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_warehouse_sk = warehouse.w_warehouse_sk))otherCondition=() -----------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_time_sk = time_dim.t_time_sk))otherCondition=() -------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_ship_mode_sk = ship_mode.sm_ship_mode_sk))otherCondition=() -----------------------------------PhysicalOlapScan[web_sales] -----------------------------------PhysicalDistribute -------------------------------------filter(sm_carrier IN ('GREAT EASTERN', 'LATVIAN')) ---------------------------------------PhysicalOlapScan[ship_mode] +----------------------------PhysicalProject +------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_time_sk = time_dim.t_time_sk))otherCondition=() --------------------------------PhysicalDistribute -----------------------------------filter((date_dim.d_year = 1998)) -------------------------------------PhysicalOlapScan[date_dim] -------------------------------PhysicalDistribute ---------------------------------filter((cast(t_time as BIGINT) <= 77621) and (time_dim.t_time >= 48821)) -----------------------------------PhysicalOlapScan[time_dim] +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_ship_mode_sk = ship_mode.sm_ship_mode_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter(sm_carrier IN ('GREAT EASTERN', 'LATVIAN')) +----------------------------------------------PhysicalOlapScan[ship_mode] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_year = 1998)) +--------------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------filter((cast(t_time as BIGINT) <= 77621) and (time_dim.t_time >= 48821)) +--------------------------------------PhysicalOlapScan[time_dim] ----------------------------PhysicalDistribute -------------------------------PhysicalOlapScan[warehouse] +------------------------------PhysicalProject +--------------------------------PhysicalOlapScan[warehouse] ----------------PhysicalProject ------------------hashAgg[GLOBAL] --------------------PhysicalDistribute ----------------------hashAgg[LOCAL] ------------------------PhysicalProject --------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_warehouse_sk = warehouse.w_warehouse_sk))otherCondition=() -----------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_time_sk = time_dim.t_time_sk))otherCondition=() -------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_ship_mode_sk = ship_mode.sm_ship_mode_sk))otherCondition=() -----------------------------------PhysicalOlapScan[catalog_sales] -----------------------------------PhysicalDistribute -------------------------------------filter(sm_carrier IN ('GREAT EASTERN', 'LATVIAN')) ---------------------------------------PhysicalOlapScan[ship_mode] +----------------------------PhysicalProject +------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_time_sk = time_dim.t_time_sk))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_ship_mode_sk = ship_mode.sm_ship_mode_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[catalog_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter(sm_carrier IN ('GREAT EASTERN', 'LATVIAN')) +----------------------------------------------PhysicalOlapScan[ship_mode] +--------------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_year = 1998)) +--------------------------------------------PhysicalOlapScan[date_dim] --------------------------------PhysicalDistribute -----------------------------------filter((date_dim.d_year = 1998)) -------------------------------------PhysicalOlapScan[date_dim] -------------------------------PhysicalDistribute ---------------------------------filter((cast(t_time as BIGINT) <= 77621) and (time_dim.t_time >= 48821)) -----------------------------------PhysicalOlapScan[time_dim] +----------------------------------PhysicalProject +------------------------------------filter((cast(t_time as BIGINT) <= 77621) and (time_dim.t_time >= 48821)) +--------------------------------------PhysicalOlapScan[time_dim] ----------------------------PhysicalDistribute -------------------------------PhysicalOlapScan[warehouse] +------------------------------PhysicalProject +--------------------------------PhysicalOlapScan[warehouse] diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query74.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query74.out index 79c348e7ee7ccf..4759bca93ba3d8 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query74.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query74.out @@ -9,13 +9,17 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ------------hashAgg[LOCAL] --------------PhysicalProject ----------------hashJoin[INNER_JOIN] hashCondition=((customer.c_customer_sk = store_sales.ss_customer_sk))otherCondition=() -------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------PhysicalOlapScan[store_sales] ---------------------PhysicalDistribute -----------------------filter(d_year IN (1999, 2000)) -------------------------PhysicalOlapScan[date_dim] ------------------PhysicalDistribute ---------------------PhysicalOlapScan[customer] +--------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------PhysicalProject +------------------------PhysicalOlapScan[store_sales] +----------------------PhysicalDistribute +------------------------PhysicalProject +--------------------------filter(d_year IN (1999, 2000)) +----------------------------PhysicalOlapScan[date_dim] +------------------PhysicalDistribute +--------------------PhysicalProject +----------------------PhysicalOlapScan[customer] ------PhysicalProject --------hashAgg[GLOBAL] ----------PhysicalDistribute @@ -24,12 +28,15 @@ PhysicalCteAnchor ( cteId=CTEId#0 ) ----------------hashJoin[INNER_JOIN] hashCondition=((customer.c_customer_sk = web_sales.ws_bill_customer_sk))otherCondition=() ------------------PhysicalDistribute --------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------PhysicalOlapScan[web_sales] +----------------------PhysicalProject +------------------------PhysicalOlapScan[web_sales] ----------------------PhysicalDistribute -------------------------filter(d_year IN (1999, 2000)) ---------------------------PhysicalOlapScan[date_dim] +------------------------PhysicalProject +--------------------------filter(d_year IN (1999, 2000)) +----------------------------PhysicalOlapScan[date_dim] ------------------PhysicalDistribute ---------------------PhysicalOlapScan[customer] +--------------------PhysicalProject +----------------------PhysicalOlapScan[customer] --PhysicalResultSink ----PhysicalTopN[MERGE_SORT] ------PhysicalDistribute diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query76.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query76.out index a9f9d40d15fc66..1cd2ee188fea85 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query76.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query76.out @@ -11,31 +11,43 @@ PhysicalResultSink ----------------PhysicalDistribute ------------------PhysicalProject --------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() -------------------------filter(ss_hdemo_sk IS NULL) ---------------------------PhysicalOlapScan[store_sales] -------------------------PhysicalDistribute ---------------------------PhysicalOlapScan[item] +----------------------PhysicalProject +------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() +--------------------------PhysicalProject +----------------------------filter(ss_hdemo_sk IS NULL) +------------------------------PhysicalOlapScan[store_sales] +--------------------------PhysicalDistribute +----------------------------PhysicalProject +------------------------------PhysicalOlapScan[item] ----------------------PhysicalDistribute -------------------------PhysicalOlapScan[date_dim] -----------------PhysicalDistribute -------------------PhysicalProject ---------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------PhysicalProject +--------------------------PhysicalOlapScan[date_dim] +----------------PhysicalProject +------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------PhysicalProject ----------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() -------------------------filter(ws_bill_addr_sk IS NULL) ---------------------------PhysicalOlapScan[web_sales] ------------------------PhysicalDistribute ---------------------------PhysicalOlapScan[item] -----------------------PhysicalDistribute +--------------------------PhysicalProject +----------------------------filter(ws_bill_addr_sk IS NULL) +------------------------------PhysicalOlapScan[web_sales] +------------------------PhysicalDistribute +--------------------------PhysicalProject +----------------------------PhysicalOlapScan[item] +--------------------PhysicalDistribute +----------------------PhysicalProject ------------------------PhysicalOlapScan[date_dim] ----------------PhysicalDistribute ------------------PhysicalProject --------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() -------------------------filter(cs_warehouse_sk IS NULL) ---------------------------PhysicalOlapScan[catalog_sales] -------------------------PhysicalDistribute ---------------------------PhysicalOlapScan[item] +----------------------PhysicalProject +------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() +--------------------------PhysicalProject +----------------------------filter(cs_warehouse_sk IS NULL) +------------------------------PhysicalOlapScan[catalog_sales] +--------------------------PhysicalDistribute +----------------------------PhysicalProject +------------------------------PhysicalOlapScan[item] ----------------------PhysicalDistribute -------------------------PhysicalOlapScan[date_dim] +------------------------PhysicalProject +--------------------------PhysicalOlapScan[date_dim] diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query77.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query77.out index d8df435aea3a8e..ea024ba5bcf863 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query77.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query77.out @@ -18,26 +18,34 @@ PhysicalResultSink ------------------------------hashAgg[LOCAL] --------------------------------PhysicalProject ----------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_store_sk = store.s_store_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[store_sales] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) +----------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[store] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[store] ------------------------PhysicalProject --------------------------hashAgg[GLOBAL] ----------------------------PhysicalDistribute ------------------------------hashAgg[LOCAL] --------------------------------PhysicalProject ----------------------------------hashJoin[INNER_JOIN] hashCondition=((store_returns.sr_store_sk = store.s_store_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_returns.sr_returned_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[store_returns] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_returns.sr_returned_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store_returns] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) +----------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[store] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[store] --------------------PhysicalProject ----------------------NestedLoopJoin[CROSS_JOIN] ------------------------PhysicalProject @@ -46,10 +54,12 @@ PhysicalResultSink ------------------------------hashAgg[LOCAL] --------------------------------PhysicalProject ----------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -------------------------------------PhysicalOlapScan[catalog_sales] +------------------------------------PhysicalProject +--------------------------------------PhysicalOlapScan[catalog_sales] ------------------------------------PhysicalDistribute ---------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) -----------------------------------------PhysicalOlapScan[date_dim] +--------------------------------------PhysicalProject +----------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) +------------------------------------------PhysicalOlapScan[date_dim] ------------------------PhysicalDistribute --------------------------PhysicalProject ----------------------------hashAgg[GLOBAL] @@ -57,10 +67,12 @@ PhysicalResultSink --------------------------------hashAgg[LOCAL] ----------------------------------PhysicalProject ------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_returns.cr_returned_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[catalog_returns] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[catalog_returns] --------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) -------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) +--------------------------------------------PhysicalOlapScan[date_dim] --------------------PhysicalProject ----------------------hashJoin[LEFT_OUTER_JOIN] hashCondition=((ws.wp_web_page_sk = wr.wp_web_page_sk))otherCondition=() ------------------------PhysicalProject @@ -69,24 +81,31 @@ PhysicalResultSink ------------------------------hashAgg[LOCAL] --------------------------------PhysicalProject ----------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_web_page_sk = web_page.wp_web_page_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[web_sales] ---------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) -------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------PhysicalProject +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject +--------------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) +----------------------------------------------PhysicalOlapScan[date_dim] ------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[web_page] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[web_page] ------------------------PhysicalProject ---------------------------hashAgg[GLOBAL] -----------------------------PhysicalDistribute -------------------------------hashAgg[LOCAL] ---------------------------------PhysicalProject -----------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_web_page_sk = web_page.wp_web_page_sk))otherCondition=() +--------------------------hashAgg[LOCAL] +----------------------------PhysicalProject +------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_web_page_sk = web_page.wp_web_page_sk))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject ------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_returns.wr_returned_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------PhysicalOlapScan[web_returns] +--------------------------------------PhysicalProject +----------------------------------------PhysicalOlapScan[web_returns] --------------------------------------PhysicalDistribute -----------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) -------------------------------------------PhysicalOlapScan[date_dim] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[web_page] +----------------------------------------PhysicalProject +------------------------------------------filter((date_dim.d_date <= '1998-09-04') and (date_dim.d_date >= '1998-08-05')) +--------------------------------------------PhysicalOlapScan[date_dim] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[web_page] diff --git a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query80.out b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query80.out index 17104ec97ae17d..c16e2d01ac236e 100644 --- a/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query80.out +++ b/regression-test/data/nereids_tpcds_shape_sf100_p0/shape/query80.out @@ -16,45 +16,68 @@ PhysicalResultSink --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject ------------------------------hashJoin[RIGHT_OUTER_JOIN] hashCondition=((store_sales.ss_item_sk = store_returns.sr_item_sk) and (store_sales.ss_ticket_number = store_returns.sr_ticket_number))otherCondition=() ---------------------------------PhysicalOlapScan[store_returns] ---------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_store_sk = store.s_store_sk))otherCondition=() -----------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_promo_sk = promotion.p_promo_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() ---------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------PhysicalOlapScan[store_sales] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[store_returns] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_store_sk = store.s_store_sk))otherCondition=() +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_promo_sk = promotion.p_promo_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_item_sk = item.i_item_sk))otherCondition=() +--------------------------------------------PhysicalDistribute +----------------------------------------------hashJoin[INNER_JOIN] hashCondition=((store_sales.ss_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------------------PhysicalProject +--------------------------------------------------PhysicalOlapScan[store_sales] +------------------------------------------------PhysicalDistribute +--------------------------------------------------PhysicalProject +----------------------------------------------------filter((date_dim.d_date <= '1998-09-27') and (date_dim.d_date >= '1998-08-28')) +------------------------------------------------------PhysicalOlapScan[date_dim] +--------------------------------------------PhysicalDistribute +----------------------------------------------PhysicalProject +------------------------------------------------filter((item.i_current_price > 50.00)) +--------------------------------------------------PhysicalOlapScan[item] ----------------------------------------PhysicalDistribute -------------------------------------------filter((date_dim.d_date <= '1998-09-27') and (date_dim.d_date >= '1998-08-28')) ---------------------------------------------PhysicalOlapScan[date_dim] +------------------------------------------PhysicalProject +--------------------------------------------filter((promotion.p_channel_tv = 'N')) +----------------------------------------------PhysicalOlapScan[promotion] --------------------------------------PhysicalDistribute -----------------------------------------filter((item.i_current_price > 50.00)) -------------------------------------------PhysicalOlapScan[item] -------------------------------------PhysicalDistribute ---------------------------------------filter((promotion.p_channel_tv = 'N')) -----------------------------------------PhysicalOlapScan[promotion] -----------------------------------PhysicalDistribute -------------------------------------PhysicalOlapScan[store] +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[store] --------------------PhysicalProject ----------------------hashAgg[GLOBAL] ------------------------PhysicalDistribute --------------------------hashAgg[LOCAL] ----------------------------PhysicalProject -------------------------------hashJoin[RIGHT_OUTER_JOIN] hashCondition=((catalog_sales.cs_item_sk = catalog_returns.cr_item_sk) and (catalog_sales.cs_order_number = catalog_returns.cr_order_number))otherCondition=() ---------------------------------PhysicalOlapScan[catalog_returns] ---------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_catalog_page_sk = catalog_page.cp_catalog_page_sk))otherCondition=() -----------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_promo_sk = promotion.p_promo_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() ---------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() -----------------------------------------PhysicalOlapScan[catalog_sales] -----------------------------------------PhysicalDistribute -------------------------------------------filter((date_dim.d_date <= '1998-09-27') and (date_dim.d_date >= '1998-08-28')) ---------------------------------------------PhysicalOlapScan[date_dim] +------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_catalog_page_sk = catalog_page.cp_catalog_page_sk))otherCondition=() +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject +------------------------------------hashJoin[RIGHT_OUTER_JOIN] hashCondition=((catalog_sales.cs_item_sk = catalog_returns.cr_item_sk) and (catalog_sales.cs_order_number = catalog_returns.cr_order_number))otherCondition=() --------------------------------------PhysicalDistribute -----------------------------------------filter((item.i_current_price > 50.00)) -------------------------------------------PhysicalOlapScan[item] -------------------------------------PhysicalDistribute ---------------------------------------filter((promotion.p_channel_tv = 'N')) -----------------------------------------PhysicalOlapScan[promotion] -----------------------------------PhysicalDistribute +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[catalog_returns] +--------------------------------------PhysicalDistribute +----------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_promo_sk = promotion.p_promo_sk))otherCondition=() +------------------------------------------PhysicalProject +--------------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_item_sk = item.i_item_sk))otherCondition=() +----------------------------------------------PhysicalDistribute +------------------------------------------------hashJoin[INNER_JOIN] hashCondition=((catalog_sales.cs_sold_date_sk = date_dim.d_date_sk))otherCondition=() +--------------------------------------------------PhysicalProject +----------------------------------------------------PhysicalOlapScan[catalog_sales] +--------------------------------------------------PhysicalDistribute +----------------------------------------------------PhysicalProject +------------------------------------------------------filter((date_dim.d_date <= '1998-09-27') and (date_dim.d_date >= '1998-08-28')) +--------------------------------------------------------PhysicalOlapScan[date_dim] +----------------------------------------------PhysicalDistribute +------------------------------------------------PhysicalProject +--------------------------------------------------filter((item.i_current_price > 50.00)) +----------------------------------------------------PhysicalOlapScan[item] +------------------------------------------PhysicalDistribute +--------------------------------------------PhysicalProject +----------------------------------------------filter((promotion.p_channel_tv = 'N')) +------------------------------------------------PhysicalOlapScan[promotion] +--------------------------------PhysicalDistribute +----------------------------------PhysicalProject ------------------------------------PhysicalOlapScan[catalog_page] --------------------PhysicalProject ----------------------hashAgg[GLOBAL] @@ -63,23 +86,31 @@ PhysicalResultSink ----------------------------PhysicalProject ------------------------------hashJoin[RIGHT_OUTER_JOIN] hashCondition=((web_sales.ws_item_sk = web_returns.wr_item_sk) and (web_sales.ws_order_number = web_returns.wr_order_number))otherCondition=() --------------------------------PhysicalDistribute -----------------------------------PhysicalOlapScan[web_returns] +----------------------------------PhysicalProject +------------------------------------PhysicalOlapScan[web_returns] --------------------------------PhysicalDistribute -----------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_web_site_sk = web_site.web_site_sk))otherCondition=() -------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() ---------------------------------------PhysicalDistribute -----------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_promo_sk = promotion.p_promo_sk))otherCondition=() -------------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() ---------------------------------------------PhysicalOlapScan[web_sales] +----------------------------------PhysicalProject +------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_web_site_sk = web_site.web_site_sk))otherCondition=() +--------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_promo_sk = promotion.p_promo_sk))otherCondition=() +----------------------------------------PhysicalProject +------------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_item_sk = item.i_item_sk))otherCondition=() --------------------------------------------PhysicalDistribute -----------------------------------------------filter((date_dim.d_date <= '1998-09-27') and (date_dim.d_date >= '1998-08-28')) -------------------------------------------------PhysicalOlapScan[date_dim] -------------------------------------------PhysicalDistribute +----------------------------------------------hashJoin[INNER_JOIN] hashCondition=((web_sales.ws_sold_date_sk = date_dim.d_date_sk))otherCondition=() +------------------------------------------------PhysicalProject +--------------------------------------------------PhysicalOlapScan[web_sales] +------------------------------------------------PhysicalDistribute +--------------------------------------------------PhysicalProject +----------------------------------------------------filter((date_dim.d_date <= '1998-09-27') and (date_dim.d_date >= '1998-08-28')) +------------------------------------------------------PhysicalOlapScan[date_dim] +--------------------------------------------PhysicalDistribute +----------------------------------------------PhysicalProject +------------------------------------------------filter((item.i_current_price > 50.00)) +--------------------------------------------------PhysicalOlapScan[item] +----------------------------------------PhysicalDistribute +------------------------------------------PhysicalProject --------------------------------------------filter((promotion.p_channel_tv = 'N')) ----------------------------------------------PhysicalOlapScan[promotion] --------------------------------------PhysicalDistribute -----------------------------------------filter((item.i_current_price > 50.00)) -------------------------------------------PhysicalOlapScan[item] -------------------------------------PhysicalDistribute ---------------------------------------PhysicalOlapScan[web_site] +----------------------------------------PhysicalProject +------------------------------------------PhysicalOlapScan[web_site] diff --git a/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf33.groovy b/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf33.groovy index b979714ccd6f6d..af3e078e026f4a 100644 --- a/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf33.groovy +++ b/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf33.groovy @@ -127,5 +127,5 @@ limit 100; // File file = new File(outFile) // file.write(getRuntimeFilters(plan)) - assertEquals("RF3[i_manufact_id->[i_manufact_id],RF2[i_item_sk->[ss_item_sk],RF1[ca_address_sk->[ss_addr_sk],RF0[d_date_sk->[ss_sold_date_sk],RF7[i_manufact_id->[i_manufact_id],RF6[i_item_sk->[cs_item_sk],RF5[ca_address_sk->[cs_bill_addr_sk],RF4[d_date_sk->[cs_sold_date_sk],RF11[i_manufact_id->[i_manufact_id],RF10[ws_item_sk->[i_item_sk],RF9[ca_address_sk->[ws_bill_addr_sk],RF8[d_date_sk->[ws_sold_date_sk]", getRuntimeFilters(plan)) + assertEquals("RF3[i_item_sk->[ss_item_sk],RF2[ca_address_sk->[ss_addr_sk],RF1[d_date_sk->[ss_sold_date_sk],RF0[i_manufact_id->[i_manufact_id],RF7[i_item_sk->[cs_item_sk],RF6[ca_address_sk->[cs_bill_addr_sk],RF5[d_date_sk->[cs_sold_date_sk],RF4[i_manufact_id->[i_manufact_id],RF11[i_manufact_id->[i_manufact_id],RF10[ws_item_sk->[i_item_sk],RF9[ca_address_sk->[ws_bill_addr_sk],RF8[d_date_sk->[ws_sold_date_sk]", getRuntimeFilters(plan)) } diff --git a/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf5.groovy b/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf5.groovy index 3ac376e4cbc491..2cc0a1cc700b51 100644 --- a/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf5.groovy +++ b/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf5.groovy @@ -180,5 +180,5 @@ suite("ds_rf5") { // File file = new File(outFile) // file.write(getRuntimeFilters(plan)) - assertEquals("RF1[s_store_sk->[ss_store_sk, sr_store_sk],RF0[d_date_sk->[ss_sold_date_sk, sr_returned_date_sk],RF3[cp_catalog_page_sk->[cs_catalog_page_sk, cr_catalog_page_sk],RF2[d_date_sk->[cs_sold_date_sk, cr_returned_date_sk],RF7[web_site_sk->[ws_web_site_sk, ws_web_site_sk],RF6[d_date_sk->[ws_sold_date_sk, wr_returned_date_sk],RF4[wr_item_sk->[ws_item_sk],RF5[wr_order_number->[ws_order_number]", getRuntimeFilters(plan)) + assertEquals("RF0[d_date_sk->[ss_sold_date_sk, sr_returned_date_sk],RF1[d_date_sk->[cs_sold_date_sk, cr_returned_date_sk],RF4[d_date_sk->[ws_sold_date_sk, wr_returned_date_sk],RF2[wr_item_sk->[ws_item_sk],RF3[wr_order_number->[ws_order_number]", getRuntimeFilters(plan)) } diff --git a/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf60.groovy b/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf60.groovy index c91fbb2c021534..3c35b50e2a14ba 100644 --- a/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf60.groovy +++ b/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf60.groovy @@ -130,5 +130,5 @@ where i_category in ('Children')) // File file = new File(outFile) // file.write(getRuntimeFilters(plan)) - assertEquals("RF3[ca_address_sk->[ss_addr_sk],RF2[i_item_sk->[ss_item_sk],RF1[d_date_sk->[ss_sold_date_sk],RF0[i_item_id->[i_item_id],RF7[ca_address_sk->[cs_bill_addr_sk],RF6[i_item_sk->[cs_item_sk],RF5[d_date_sk->[cs_sold_date_sk],RF4[i_item_id->[i_item_id],RF11[ca_address_sk->[ws_bill_addr_sk],RF10[i_item_sk->[ws_item_sk],RF9[d_date_sk->[ws_sold_date_sk],RF8[i_item_id->[i_item_id]", getRuntimeFilters(plan)) + assertEquals("RF3[i_item_sk->[ss_item_sk],RF2[ca_address_sk->[ss_addr_sk],RF1[d_date_sk->[ss_sold_date_sk],RF0[i_item_id->[i_item_id],RF7[i_item_sk->[cs_item_sk],RF6[ca_address_sk->[cs_bill_addr_sk],RF5[d_date_sk->[cs_sold_date_sk],RF4[i_item_id->[i_item_id],RF11[i_item_sk->[ws_item_sk],RF10[ca_address_sk->[ws_bill_addr_sk],RF9[d_date_sk->[ws_sold_date_sk],RF8[i_item_id->[i_item_id]", getRuntimeFilters(plan)) } diff --git a/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf80.groovy b/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf80.groovy index a41bdd43564f02..de392b8bf54c1a 100644 --- a/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf80.groovy +++ b/regression-test/suites/nereids_tpcds_shape_sf100_p0/rf/ds_rf80.groovy @@ -148,5 +148,5 @@ group by web_site_id) // File file = new File(outFile) // file.write(getRuntimeFilters(plan)) - assertEquals("RF4[ss_item_sk->[sr_item_sk],RF5[ss_ticket_number->[sr_ticket_number],RF3[s_store_sk->[ss_store_sk],RF2[p_promo_sk->[ss_promo_sk],RF1[i_item_sk->[ss_item_sk],RF0[d_date_sk->[ss_sold_date_sk],RF10[cs_item_sk->[cr_item_sk],RF11[cs_order_number->[cr_order_number],RF9[cp_catalog_page_sk->[cs_catalog_page_sk],RF8[p_promo_sk->[cs_promo_sk],RF7[i_item_sk->[cs_item_sk],RF6[d_date_sk->[cs_sold_date_sk],RF16[ws_item_sk->[wr_item_sk],RF17[ws_order_number->[wr_order_number],RF15[web_site_sk->[ws_web_site_sk],RF14[i_item_sk->[ws_item_sk],RF13[p_promo_sk->[ws_promo_sk],RF12[d_date_sk->[ws_sold_date_sk]", getRuntimeFilters(plan)) + assertEquals("RF4[ss_item_sk->[sr_item_sk],RF5[ss_ticket_number->[sr_ticket_number],RF3[s_store_sk->[ss_store_sk],RF2[p_promo_sk->[ss_promo_sk],RF1[i_item_sk->[ss_item_sk],RF0[d_date_sk->[ss_sold_date_sk],RF11[cp_catalog_page_sk->[cs_catalog_page_sk],RF9[cs_item_sk->[cr_item_sk],RF10[cs_order_number->[cr_order_number],RF8[p_promo_sk->[cs_promo_sk],RF7[i_item_sk->[cs_item_sk],RF6[d_date_sk->[cs_sold_date_sk],RF16[ws_item_sk->[wr_item_sk],RF17[ws_order_number->[wr_order_number],RF15[web_site_sk->[ws_web_site_sk],RF14[p_promo_sk->[ws_promo_sk],RF13[i_item_sk->[ws_item_sk],RF12[d_date_sk->[ws_sold_date_sk]", getRuntimeFilters(plan)) }