== Physical Plan ==
* CometColumnarToRow (69)
+- CometHashAggregate (68)
   +- CometExchange (67)
      +- CometHashAggregate (66)
         +- CometUnion (65)
            :- CometProject (47)
            :  +- CometBroadcastHashJoin (46)
            :     :- CometProject (41)
            :     :  +- CometSortMergeJoin (40)
            :     :     :- CometSort (25)
            :     :     :  +- CometColumnarExchange (24)
            :     :     :     +- * Project (23)
            :     :     :        +- * BroadcastHashJoin LeftSemi BuildRight (22)
            :     :     :           :- * ColumnarToRow (2)
            :     :     :           :  +- Scan parquet spark_catalog.default.catalog_sales (1)
            :     :     :           +- BroadcastExchange (21)
            :     :     :              +- * Project (20)
            :     :     :                 +- * Filter (19)
            :     :     :                    +- * HashAggregate (18)
            :     :     :                       +- * CometColumnarToRow (17)
            :     :     :                          +- CometColumnarExchange (16)
            :     :     :                             +- * HashAggregate (15)
            :     :     :                                +- * Project (14)
            :     :     :                                   +- * BroadcastHashJoin Inner BuildRight (13)
            :     :     :                                      :- * Project (8)
            :     :     :                                      :  +- * BroadcastHashJoin Inner BuildRight (7)
            :     :     :                                      :     :- * Filter (5)
            :     :     :                                      :     :  +- * ColumnarToRow (4)
            :     :     :                                      :     :     +- Scan parquet spark_catalog.default.store_sales (3)
            :     :     :                                      :     +- ReusedExchange (6)
            :     :     :                                      +- BroadcastExchange (12)
            :     :     :                                         +- * CometColumnarToRow (11)
            :     :     :                                            +- CometFilter (10)
            :     :     :                                               +- CometNativeScan parquet spark_catalog.default.item (9)
            :     :     +- CometSort (39)
            :     :        +- CometProject (38)
            :     :           +- CometFilter (37)
            :     :              +- CometHashAggregate (36)
            :     :                 +- CometExchange (35)
            :     :                    +- CometHashAggregate (34)
            :     :                       +- CometProject (33)
            :     :                          +- CometBroadcastHashJoin (32)
            :     :                             :- CometProject (28)
            :     :                             :  +- CometFilter (27)
            :     :                             :     +- CometNativeScan parquet spark_catalog.default.store_sales (26)
            :     :                             +- CometBroadcastExchange (31)
            :     :                                +- CometFilter (30)
            :     :                                   +- CometNativeScan parquet spark_catalog.default.customer (29)
            :     +- CometBroadcastExchange (45)
            :        +- CometProject (44)
            :           +- CometFilter (43)
            :              +- CometNativeScan parquet spark_catalog.default.date_dim (42)
            +- CometProject (64)
               +- CometBroadcastHashJoin (63)
                  :- CometProject (61)
                  :  +- CometSortMergeJoin (60)
                  :     :- CometSort (54)
                  :     :  +- CometColumnarExchange (53)
                  :     :     +- * Project (52)
                  :     :        +- * BroadcastHashJoin LeftSemi BuildRight (51)
                  :     :           :- * ColumnarToRow (49)
                  :     :           :  +- Scan parquet spark_catalog.default.web_sales (48)
                  :     :           +- ReusedExchange (50)
                  :     +- CometSort (59)
                  :        +- CometProject (58)
                  :           +- CometFilter (57)
                  :              +- CometHashAggregate (56)
                  :                 +- ReusedExchange (55)
                  +- ReusedExchange (62)


(1) Scan parquet spark_catalog.default.catalog_sales
Output [5]: [cs_bill_customer_sk#1, cs_item_sk#2, cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(cs_sold_date_sk#5), dynamicpruningexpression(cs_sold_date_sk#5 IN dynamicpruning#6)]
ReadSchema: struct<cs_bill_customer_sk:int,cs_item_sk:int,cs_quantity:int,cs_list_price:decimal(7,2)>

(2) ColumnarToRow [codegen id : 5]
Input [5]: [cs_bill_customer_sk#1, cs_item_sk#2, cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]

(3) Scan parquet spark_catalog.default.store_sales
Output [2]: [ss_item_sk#7, ss_sold_date_sk#8]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(ss_sold_date_sk#8), dynamicpruningexpression(ss_sold_date_sk#8 IN dynamicpruning#9)]
PushedFilters: [IsNotNull(ss_item_sk)]
ReadSchema: struct<ss_item_sk:int>

(4) ColumnarToRow [codegen id : 3]
Input [2]: [ss_item_sk#7, ss_sold_date_sk#8]

(5) Filter [codegen id : 3]
Input [2]: [ss_item_sk#7, ss_sold_date_sk#8]
Condition : isnotnull(ss_item_sk#7)

(6) ReusedExchange [Reuses operator id: 79]
Output [2]: [d_date_sk#10, d_date#11]

(7) BroadcastHashJoin [codegen id : 3]
Left keys [1]: [ss_sold_date_sk#8]
Right keys [1]: [d_date_sk#10]
Join type: Inner
Join condition: None

(8) Project [codegen id : 3]
Output [2]: [ss_item_sk#7, d_date#11]
Input [4]: [ss_item_sk#7, ss_sold_date_sk#8, d_date_sk#10, d_date#11]

(9) CometNativeScan parquet spark_catalog.default.item
Output [2]: [i_item_sk#12, i_item_desc#13]
Batched: true
Location [not included in comparison]/{warehouse_dir}/item]
PushedFilters: [IsNotNull(i_item_sk)]
ReadSchema: struct<i_item_sk:int,i_item_desc:string>

(10) CometFilter
Input [2]: [i_item_sk#12, i_item_desc#13]
Condition : isnotnull(i_item_sk#12)

(11) CometColumnarToRow [codegen id : 2]
Input [2]: [i_item_sk#12, i_item_desc#13]

(12) BroadcastExchange
Input [2]: [i_item_sk#12, i_item_desc#13]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, false] as bigint)),false), [plan_id=1]

(13) BroadcastHashJoin [codegen id : 3]
Left keys [1]: [ss_item_sk#7]
Right keys [1]: [i_item_sk#12]
Join type: Inner
Join condition: None

(14) Project [codegen id : 3]
Output [3]: [d_date#11, i_item_sk#12, substr(i_item_desc#13, 1, 30) AS _groupingexpression#14]
Input [4]: [ss_item_sk#7, d_date#11, i_item_sk#12, i_item_desc#13]

(15) HashAggregate [codegen id : 3]
Input [3]: [d_date#11, i_item_sk#12, _groupingexpression#14]
Keys [3]: [_groupingexpression#14, i_item_sk#12, d_date#11]
Functions [1]: [partial_count(1)]
Aggregate Attributes [1]: [count#15]
Results [4]: [_groupingexpression#14, i_item_sk#12, d_date#11, count#16]

(16) CometColumnarExchange
Input [4]: [_groupingexpression#14, i_item_sk#12, d_date#11, count#16]
Arguments: hashpartitioning(_groupingexpression#14, i_item_sk#12, d_date#11, 5), ENSURE_REQUIREMENTS, CometColumnarShuffle, [plan_id=2]

(17) CometColumnarToRow [codegen id : 4]
Input [4]: [_groupingexpression#14, i_item_sk#12, d_date#11, count#16]

(18) HashAggregate [codegen id : 4]
Input [4]: [_groupingexpression#14, i_item_sk#12, d_date#11, count#16]
Keys [3]: [_groupingexpression#14, i_item_sk#12, d_date#11]
Functions [1]: [count(1)]
Aggregate Attributes [1]: [count(1)#17]
Results [2]: [i_item_sk#12 AS item_sk#18, count(1)#17 AS cnt#19]

(19) Filter [codegen id : 4]
Input [2]: [item_sk#18, cnt#19]
Condition : (cnt#19 > 4)

(20) Project [codegen id : 4]
Output [1]: [item_sk#18]
Input [2]: [item_sk#18, cnt#19]

(21) BroadcastExchange
Input [1]: [item_sk#18]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, true] as bigint)),false), [plan_id=3]

(22) BroadcastHashJoin [codegen id : 5]
Left keys [1]: [cs_item_sk#2]
Right keys [1]: [item_sk#18]
Join type: LeftSemi
Join condition: None

(23) Project [codegen id : 5]
Output [4]: [cs_bill_customer_sk#1, cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]
Input [5]: [cs_bill_customer_sk#1, cs_item_sk#2, cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]

(24) CometColumnarExchange
Input [4]: [cs_bill_customer_sk#1, cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]
Arguments: hashpartitioning(cs_bill_customer_sk#1, 5), ENSURE_REQUIREMENTS, CometColumnarShuffle, [plan_id=4]

(25) CometSort
Input [4]: [cs_bill_customer_sk#1, cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]
Arguments: [cs_bill_customer_sk#1, cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5], [cs_bill_customer_sk#1 ASC NULLS FIRST]

(26) CometNativeScan parquet spark_catalog.default.store_sales
Output [4]: [ss_customer_sk#20, ss_quantity#21, ss_sales_price#22, ss_sold_date_sk#23]
Batched: true
Location [not included in comparison]/{warehouse_dir}/store_sales]
PushedFilters: [IsNotNull(ss_customer_sk)]
ReadSchema: struct<ss_customer_sk:int,ss_quantity:int,ss_sales_price:decimal(7,2)>

(27) CometFilter
Input [4]: [ss_customer_sk#20, ss_quantity#21, ss_sales_price#22, ss_sold_date_sk#23]
Condition : isnotnull(ss_customer_sk#20)

(28) CometProject
Input [4]: [ss_customer_sk#20, ss_quantity#21, ss_sales_price#22, ss_sold_date_sk#23]
Arguments: [ss_customer_sk#20, ss_quantity#21, ss_sales_price#22], [ss_customer_sk#20, ss_quantity#21, ss_sales_price#22]

(29) CometNativeScan parquet spark_catalog.default.customer
Output [1]: [c_customer_sk#24]
Batched: true
Location [not included in comparison]/{warehouse_dir}/customer]
PushedFilters: [IsNotNull(c_customer_sk)]
ReadSchema: struct<c_customer_sk:int>

(30) CometFilter
Input [1]: [c_customer_sk#24]
Condition : isnotnull(c_customer_sk#24)

(31) CometBroadcastExchange
Input [1]: [c_customer_sk#24]
Arguments: [c_customer_sk#24]

(32) CometBroadcastHashJoin
Left output [3]: [ss_customer_sk#20, ss_quantity#21, ss_sales_price#22]
Right output [1]: [c_customer_sk#24]
Arguments: [ss_customer_sk#20], [c_customer_sk#24], Inner, BuildRight

(33) CometProject
Input [4]: [ss_customer_sk#20, ss_quantity#21, ss_sales_price#22, c_customer_sk#24]
Arguments: [ss_quantity#21, ss_sales_price#22, c_customer_sk#24], [ss_quantity#21, ss_sales_price#22, c_customer_sk#24]

(34) CometHashAggregate
Input [3]: [ss_quantity#21, ss_sales_price#22, c_customer_sk#24]
Keys [1]: [c_customer_sk#24]
Functions [1]: [partial_sum((cast(ss_quantity#21 as decimal(10,0)) * ss_sales_price#22))]

(35) CometExchange
Input [3]: [c_customer_sk#24, sum#25, isEmpty#26]
Arguments: hashpartitioning(c_customer_sk#24, 5), ENSURE_REQUIREMENTS, CometNativeShuffle, [plan_id=5]

(36) CometHashAggregate
Input [3]: [c_customer_sk#24, sum#25, isEmpty#26]
Keys [1]: [c_customer_sk#24]
Functions [1]: [sum((cast(ss_quantity#21 as decimal(10,0)) * ss_sales_price#22))]

(37) CometFilter
Input [2]: [c_customer_sk#24, ssales#27]
Condition : (isnotnull(ssales#27) AND (cast(ssales#27 as decimal(38,8)) > (0.500000 * Subquery scalar-subquery#28, [id=#29])))

(38) CometProject
Input [2]: [c_customer_sk#24, ssales#27]
Arguments: [c_customer_sk#24], [c_customer_sk#24]

(39) CometSort
Input [1]: [c_customer_sk#24]
Arguments: [c_customer_sk#24], [c_customer_sk#24 ASC NULLS FIRST]

(40) CometSortMergeJoin
Left output [4]: [cs_bill_customer_sk#1, cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]
Right output [1]: [c_customer_sk#24]
Arguments: [cs_bill_customer_sk#1], [c_customer_sk#24], LeftSemi

(41) CometProject
Input [4]: [cs_bill_customer_sk#1, cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]
Arguments: [cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5], [cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]

(42) CometNativeScan parquet spark_catalog.default.date_dim
Output [3]: [d_date_sk#30, d_year#31, d_moy#32]
Batched: true
Location [not included in comparison]/{warehouse_dir}/date_dim]
PushedFilters: [IsNotNull(d_year), IsNotNull(d_moy), EqualTo(d_year,2000), EqualTo(d_moy,2), IsNotNull(d_date_sk)]
ReadSchema: struct<d_date_sk:int,d_year:int,d_moy:int>

(43) CometFilter
Input [3]: [d_date_sk#30, d_year#31, d_moy#32]
Condition : ((((isnotnull(d_year#31) AND isnotnull(d_moy#32)) AND (d_year#31 = 2000)) AND (d_moy#32 = 2)) AND isnotnull(d_date_sk#30))

(44) CometProject
Input [3]: [d_date_sk#30, d_year#31, d_moy#32]
Arguments: [d_date_sk#30], [d_date_sk#30]

(45) CometBroadcastExchange
Input [1]: [d_date_sk#30]
Arguments: [d_date_sk#30]

(46) CometBroadcastHashJoin
Left output [3]: [cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5]
Right output [1]: [d_date_sk#30]
Arguments: [cs_sold_date_sk#5], [d_date_sk#30], Inner, BuildRight

(47) CometProject
Input [4]: [cs_quantity#3, cs_list_price#4, cs_sold_date_sk#5, d_date_sk#30]
Arguments: [sales#33], [(cast(cs_quantity#3 as decimal(10,0)) * cs_list_price#4) AS sales#33]

(48) Scan parquet spark_catalog.default.web_sales
Output [5]: [ws_item_sk#34, ws_bill_customer_sk#35, ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(ws_sold_date_sk#38), dynamicpruningexpression(ws_sold_date_sk#38 IN dynamicpruning#6)]
ReadSchema: struct<ws_item_sk:int,ws_bill_customer_sk:int,ws_quantity:int,ws_list_price:decimal(7,2)>

(49) ColumnarToRow [codegen id : 10]
Input [5]: [ws_item_sk#34, ws_bill_customer_sk#35, ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]

(50) ReusedExchange [Reuses operator id: 21]
Output [1]: [item_sk#39]

(51) BroadcastHashJoin [codegen id : 10]
Left keys [1]: [ws_item_sk#34]
Right keys [1]: [item_sk#39]
Join type: LeftSemi
Join condition: None

(52) Project [codegen id : 10]
Output [4]: [ws_bill_customer_sk#35, ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]
Input [5]: [ws_item_sk#34, ws_bill_customer_sk#35, ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]

(53) CometColumnarExchange
Input [4]: [ws_bill_customer_sk#35, ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]
Arguments: hashpartitioning(ws_bill_customer_sk#35, 5), ENSURE_REQUIREMENTS, CometColumnarShuffle, [plan_id=6]

(54) CometSort
Input [4]: [ws_bill_customer_sk#35, ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]
Arguments: [ws_bill_customer_sk#35, ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38], [ws_bill_customer_sk#35 ASC NULLS FIRST]

(55) ReusedExchange [Reuses operator id: 35]
Output [3]: [c_customer_sk#40, sum#41, isEmpty#42]

(56) CometHashAggregate
Input [3]: [c_customer_sk#40, sum#41, isEmpty#42]
Keys [1]: [c_customer_sk#40]
Functions [1]: [sum((cast(ss_quantity#43 as decimal(10,0)) * ss_sales_price#44))]

(57) CometFilter
Input [2]: [c_customer_sk#40, ssales#45]
Condition : (isnotnull(ssales#45) AND (cast(ssales#45 as decimal(38,8)) > (0.500000 * ReusedSubquery Subquery scalar-subquery#28, [id=#29])))

(58) CometProject
Input [2]: [c_customer_sk#40, ssales#45]
Arguments: [c_customer_sk#40], [c_customer_sk#40]

(59) CometSort
Input [1]: [c_customer_sk#40]
Arguments: [c_customer_sk#40], [c_customer_sk#40 ASC NULLS FIRST]

(60) CometSortMergeJoin
Left output [4]: [ws_bill_customer_sk#35, ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]
Right output [1]: [c_customer_sk#40]
Arguments: [ws_bill_customer_sk#35], [c_customer_sk#40], LeftSemi

(61) CometProject
Input [4]: [ws_bill_customer_sk#35, ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]
Arguments: [ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38], [ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]

(62) ReusedExchange [Reuses operator id: 45]
Output [1]: [d_date_sk#46]

(63) CometBroadcastHashJoin
Left output [3]: [ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38]
Right output [1]: [d_date_sk#46]
Arguments: [ws_sold_date_sk#38], [d_date_sk#46], Inner, BuildRight

(64) CometProject
Input [4]: [ws_quantity#36, ws_list_price#37, ws_sold_date_sk#38, d_date_sk#46]
Arguments: [sales#47], [(cast(ws_quantity#36 as decimal(10,0)) * ws_list_price#37) AS sales#47]

(65) CometUnion
Child 0 Input [1]: [sales#33]
Child 1 Input [1]: [sales#47]

(66) CometHashAggregate
Input [1]: [sales#33]
Keys: []
Functions [1]: [partial_sum(sales#33)]

(67) CometExchange
Input [2]: [sum#48, isEmpty#49]
Arguments: SinglePartition, ENSURE_REQUIREMENTS, CometNativeShuffle, [plan_id=7]

(68) CometHashAggregate
Input [2]: [sum#48, isEmpty#49]
Keys: []
Functions [1]: [sum(sales#33)]

(69) CometColumnarToRow [codegen id : 11]
Input [1]: [sum(sales)#50]

===== Subqueries =====

Subquery:1 Hosting operator id = 1 Hosting Expression = cs_sold_date_sk#5 IN dynamicpruning#6
BroadcastExchange (74)
+- * CometColumnarToRow (73)
   +- CometProject (72)
      +- CometFilter (71)
         +- CometNativeScan parquet spark_catalog.default.date_dim (70)


(70) CometNativeScan parquet spark_catalog.default.date_dim
Output [3]: [d_date_sk#30, d_year#31, d_moy#32]
Batched: true
Location [not included in comparison]/{warehouse_dir}/date_dim]
PushedFilters: [IsNotNull(d_year), IsNotNull(d_moy), EqualTo(d_year,2000), EqualTo(d_moy,2), IsNotNull(d_date_sk)]
ReadSchema: struct<d_date_sk:int,d_year:int,d_moy:int>

(71) CometFilter
Input [3]: [d_date_sk#30, d_year#31, d_moy#32]
Condition : ((((isnotnull(d_year#31) AND isnotnull(d_moy#32)) AND (d_year#31 = 2000)) AND (d_moy#32 = 2)) AND isnotnull(d_date_sk#30))

(72) CometProject
Input [3]: [d_date_sk#30, d_year#31, d_moy#32]
Arguments: [d_date_sk#30], [d_date_sk#30]

(73) CometColumnarToRow [codegen id : 1]
Input [1]: [d_date_sk#30]

(74) BroadcastExchange
Input [1]: [d_date_sk#30]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, true] as bigint)),false), [plan_id=8]

Subquery:2 Hosting operator id = 3 Hosting Expression = ss_sold_date_sk#8 IN dynamicpruning#9
BroadcastExchange (79)
+- * CometColumnarToRow (78)
   +- CometProject (77)
      +- CometFilter (76)
         +- CometNativeScan parquet spark_catalog.default.date_dim (75)


(75) CometNativeScan parquet spark_catalog.default.date_dim
Output [3]: [d_date_sk#10, d_date#11, d_year#51]
Batched: true
Location [not included in comparison]/{warehouse_dir}/date_dim]
PushedFilters: [In(d_year, [2000,2001,2002,2003]), IsNotNull(d_date_sk)]
ReadSchema: struct<d_date_sk:int,d_date:date,d_year:int>

(76) CometFilter
Input [3]: [d_date_sk#10, d_date#11, d_year#51]
Condition : (d_year#51 IN (2000,2001,2002,2003) AND isnotnull(d_date_sk#10))

(77) CometProject
Input [3]: [d_date_sk#10, d_date#11, d_year#51]
Arguments: [d_date_sk#10, d_date#11], [d_date_sk#10, d_date#11]

(78) CometColumnarToRow [codegen id : 1]
Input [2]: [d_date_sk#10, d_date#11]

(79) BroadcastExchange
Input [2]: [d_date_sk#10, d_date#11]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, true] as bigint)),false), [plan_id=9]

Subquery:3 Hosting operator id = 37 Hosting Expression = Subquery scalar-subquery#28, [id=#29]
* HashAggregate (99)
+- * CometColumnarToRow (98)
   +- CometColumnarExchange (97)
      +- * HashAggregate (96)
         +- * HashAggregate (95)
            +- * CometColumnarToRow (94)
               +- CometColumnarExchange (93)
                  +- * HashAggregate (92)
                     +- * Project (91)
                        +- * BroadcastHashJoin Inner BuildRight (90)
                           :- * Project (88)
                           :  +- * BroadcastHashJoin Inner BuildRight (87)
                           :     :- * Filter (82)
                           :     :  +- * ColumnarToRow (81)
                           :     :     +- Scan parquet spark_catalog.default.store_sales (80)
                           :     +- BroadcastExchange (86)
                           :        +- * CometColumnarToRow (85)
                           :           +- CometFilter (84)
                           :              +- CometNativeScan parquet spark_catalog.default.customer (83)
                           +- ReusedExchange (89)


(80) Scan parquet spark_catalog.default.store_sales
Output [4]: [ss_customer_sk#52, ss_quantity#53, ss_sales_price#54, ss_sold_date_sk#55]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(ss_sold_date_sk#55), dynamicpruningexpression(ss_sold_date_sk#55 IN dynamicpruning#56)]
PushedFilters: [IsNotNull(ss_customer_sk)]
ReadSchema: struct<ss_customer_sk:int,ss_quantity:int,ss_sales_price:decimal(7,2)>

(81) ColumnarToRow [codegen id : 3]
Input [4]: [ss_customer_sk#52, ss_quantity#53, ss_sales_price#54, ss_sold_date_sk#55]

(82) Filter [codegen id : 3]
Input [4]: [ss_customer_sk#52, ss_quantity#53, ss_sales_price#54, ss_sold_date_sk#55]
Condition : isnotnull(ss_customer_sk#52)

(83) CometNativeScan parquet spark_catalog.default.customer
Output [1]: [c_customer_sk#57]
Batched: true
Location [not included in comparison]/{warehouse_dir}/customer]
PushedFilters: [IsNotNull(c_customer_sk)]
ReadSchema: struct<c_customer_sk:int>

(84) CometFilter
Input [1]: [c_customer_sk#57]
Condition : isnotnull(c_customer_sk#57)

(85) CometColumnarToRow [codegen id : 1]
Input [1]: [c_customer_sk#57]

(86) BroadcastExchange
Input [1]: [c_customer_sk#57]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, false] as bigint)),false), [plan_id=10]

(87) BroadcastHashJoin [codegen id : 3]
Left keys [1]: [ss_customer_sk#52]
Right keys [1]: [c_customer_sk#57]
Join type: Inner
Join condition: None

(88) Project [codegen id : 3]
Output [4]: [ss_quantity#53, ss_sales_price#54, ss_sold_date_sk#55, c_customer_sk#57]
Input [5]: [ss_customer_sk#52, ss_quantity#53, ss_sales_price#54, ss_sold_date_sk#55, c_customer_sk#57]

(89) ReusedExchange [Reuses operator id: 104]
Output [1]: [d_date_sk#58]

(90) BroadcastHashJoin [codegen id : 3]
Left keys [1]: [ss_sold_date_sk#55]
Right keys [1]: [d_date_sk#58]
Join type: Inner
Join condition: None

(91) Project [codegen id : 3]
Output [3]: [ss_quantity#53, ss_sales_price#54, c_customer_sk#57]
Input [5]: [ss_quantity#53, ss_sales_price#54, ss_sold_date_sk#55, c_customer_sk#57, d_date_sk#58]

(92) HashAggregate [codegen id : 3]
Input [3]: [ss_quantity#53, ss_sales_price#54, c_customer_sk#57]
Keys [1]: [c_customer_sk#57]
Functions [1]: [partial_sum((cast(ss_quantity#53 as decimal(10,0)) * ss_sales_price#54))]
Aggregate Attributes [2]: [sum#59, isEmpty#60]
Results [3]: [c_customer_sk#57, sum#61, isEmpty#62]

(93) CometColumnarExchange
Input [3]: [c_customer_sk#57, sum#61, isEmpty#62]
Arguments: hashpartitioning(c_customer_sk#57, 5), ENSURE_REQUIREMENTS, CometColumnarShuffle, [plan_id=11]

(94) CometColumnarToRow [codegen id : 4]
Input [3]: [c_customer_sk#57, sum#61, isEmpty#62]

(95) HashAggregate [codegen id : 4]
Input [3]: [c_customer_sk#57, sum#61, isEmpty#62]
Keys [1]: [c_customer_sk#57]
Functions [1]: [sum((cast(ss_quantity#53 as decimal(10,0)) * ss_sales_price#54))]
Aggregate Attributes [1]: [sum((cast(ss_quantity#53 as decimal(10,0)) * ss_sales_price#54))#63]
Results [1]: [sum((cast(ss_quantity#53 as decimal(10,0)) * ss_sales_price#54))#63 AS csales#64]

(96) HashAggregate [codegen id : 4]
Input [1]: [csales#64]
Keys: []
Functions [1]: [partial_max(csales#64)]
Aggregate Attributes [1]: [max#65]
Results [1]: [max#66]

(97) CometColumnarExchange
Input [1]: [max#66]
Arguments: SinglePartition, ENSURE_REQUIREMENTS, CometColumnarShuffle, [plan_id=12]

(98) CometColumnarToRow [codegen id : 5]
Input [1]: [max#66]

(99) HashAggregate [codegen id : 5]
Input [1]: [max#66]
Keys: []
Functions [1]: [max(csales#64)]
Aggregate Attributes [1]: [max(csales#64)#67]
Results [1]: [max(csales#64)#67 AS tpcds_cmax#68]

Subquery:4 Hosting operator id = 80 Hosting Expression = ss_sold_date_sk#55 IN dynamicpruning#56
BroadcastExchange (104)
+- * CometColumnarToRow (103)
   +- CometProject (102)
      +- CometFilter (101)
         +- CometNativeScan parquet spark_catalog.default.date_dim (100)


(100) CometNativeScan parquet spark_catalog.default.date_dim
Output [2]: [d_date_sk#58, d_year#69]
Batched: true
Location [not included in comparison]/{warehouse_dir}/date_dim]
PushedFilters: [In(d_year, [2000,2001,2002,2003]), IsNotNull(d_date_sk)]
ReadSchema: struct<d_date_sk:int,d_year:int>

(101) CometFilter
Input [2]: [d_date_sk#58, d_year#69]
Condition : (d_year#69 IN (2000,2001,2002,2003) AND isnotnull(d_date_sk#58))

(102) CometProject
Input [2]: [d_date_sk#58, d_year#69]
Arguments: [d_date_sk#58], [d_date_sk#58]

(103) CometColumnarToRow [codegen id : 1]
Input [1]: [d_date_sk#58]

(104) BroadcastExchange
Input [1]: [d_date_sk#58]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, true] as bigint)),false), [plan_id=13]

Subquery:5 Hosting operator id = 48 Hosting Expression = ws_sold_date_sk#38 IN dynamicpruning#6

Subquery:6 Hosting operator id = 57 Hosting Expression = ReusedSubquery Subquery scalar-subquery#28, [id=#29]


