== Physical Plan ==
* Sort (99)
+- Exchange (98)
   +- * Project (97)
      +- * BroadcastHashJoin Inner BuildRight (96)
         :- * Project (82)
         :  +- * BroadcastHashJoin Inner BuildRight (81)
         :     :- * BroadcastHashJoin Inner BuildRight (67)
         :     :  :- * Project (53)
         :     :  :  +- * BroadcastHashJoin Inner BuildRight (52)
         :     :  :     :- * BroadcastHashJoin Inner BuildRight (35)
         :     :  :     :  :- * HashAggregate (18)
         :     :  :     :  :  +- Exchange (17)
         :     :  :     :  :     +- * HashAggregate (16)
         :     :  :     :  :        +- * Project (15)
         :     :  :     :  :           +- * BroadcastHashJoin Inner BuildRight (14)
         :     :  :     :  :              :- * Project (9)
         :     :  :     :  :              :  +- * BroadcastHashJoin Inner BuildRight (8)
         :     :  :     :  :              :     :- * Filter (3)
         :     :  :     :  :              :     :  +- * ColumnarToRow (2)
         :     :  :     :  :              :     :     +- Scan parquet spark_catalog.default.store_sales (1)
         :     :  :     :  :              :     +- BroadcastExchange (7)
         :     :  :     :  :              :        +- * Filter (6)
         :     :  :     :  :              :           +- * ColumnarToRow (5)
         :     :  :     :  :              :              +- Scan parquet spark_catalog.default.date_dim (4)
         :     :  :     :  :              +- BroadcastExchange (13)
         :     :  :     :  :                 +- * Filter (12)
         :     :  :     :  :                    +- * ColumnarToRow (11)
         :     :  :     :  :                       +- Scan parquet spark_catalog.default.customer_address (10)
         :     :  :     :  +- BroadcastExchange (34)
         :     :  :     :     +- * HashAggregate (33)
         :     :  :     :        +- Exchange (32)
         :     :  :     :           +- * HashAggregate (31)
         :     :  :     :              +- * Project (30)
         :     :  :     :                 +- * BroadcastHashJoin Inner BuildRight (29)
         :     :  :     :                    :- * Project (27)
         :     :  :     :                    :  +- * BroadcastHashJoin Inner BuildRight (26)
         :     :  :     :                    :     :- * Filter (21)
         :     :  :     :                    :     :  +- * ColumnarToRow (20)
         :     :  :     :                    :     :     +- Scan parquet spark_catalog.default.store_sales (19)
         :     :  :     :                    :     +- BroadcastExchange (25)
         :     :  :     :                    :        +- * Filter (24)
         :     :  :     :                    :           +- * ColumnarToRow (23)
         :     :  :     :                    :              +- Scan parquet spark_catalog.default.date_dim (22)
         :     :  :     :                    +- ReusedExchange (28)
         :     :  :     +- BroadcastExchange (51)
         :     :  :        +- * HashAggregate (50)
         :     :  :           +- Exchange (49)
         :     :  :              +- * HashAggregate (48)
         :     :  :                 +- * Project (47)
         :     :  :                    +- * BroadcastHashJoin Inner BuildRight (46)
         :     :  :                       :- * Project (44)
         :     :  :                       :  +- * BroadcastHashJoin Inner BuildRight (43)
         :     :  :                       :     :- * Filter (38)
         :     :  :                       :     :  +- * ColumnarToRow (37)
         :     :  :                       :     :     +- Scan parquet spark_catalog.default.store_sales (36)
         :     :  :                       :     +- BroadcastExchange (42)
         :     :  :                       :        +- * Filter (41)
         :     :  :                       :           +- * ColumnarToRow (40)
         :     :  :                       :              +- Scan parquet spark_catalog.default.date_dim (39)
         :     :  :                       +- ReusedExchange (45)
         :     :  +- BroadcastExchange (66)
         :     :     +- * HashAggregate (65)
         :     :        +- Exchange (64)
         :     :           +- * HashAggregate (63)
         :     :              +- * Project (62)
         :     :                 +- * BroadcastHashJoin Inner BuildRight (61)
         :     :                    :- * Project (59)
         :     :                    :  +- * BroadcastHashJoin Inner BuildRight (58)
         :     :                    :     :- * Filter (56)
         :     :                    :     :  +- * ColumnarToRow (55)
         :     :                    :     :     +- Scan parquet spark_catalog.default.web_sales (54)
         :     :                    :     +- ReusedExchange (57)
         :     :                    +- ReusedExchange (60)
         :     +- BroadcastExchange (80)
         :        +- * HashAggregate (79)
         :           +- Exchange (78)
         :              +- * HashAggregate (77)
         :                 +- * Project (76)
         :                    +- * BroadcastHashJoin Inner BuildRight (75)
         :                       :- * Project (73)
         :                       :  +- * BroadcastHashJoin Inner BuildRight (72)
         :                       :     :- * Filter (70)
         :                       :     :  +- * ColumnarToRow (69)
         :                       :     :     +- Scan parquet spark_catalog.default.web_sales (68)
         :                       :     +- ReusedExchange (71)
         :                       +- ReusedExchange (74)
         +- BroadcastExchange (95)
            +- * HashAggregate (94)
               +- Exchange (93)
                  +- * HashAggregate (92)
                     +- * Project (91)
                        +- * BroadcastHashJoin Inner BuildRight (90)
                           :- * Project (88)
                           :  +- * BroadcastHashJoin Inner BuildRight (87)
                           :     :- * Filter (85)
                           :     :  +- * ColumnarToRow (84)
                           :     :     +- Scan parquet spark_catalog.default.web_sales (83)
                           :     +- ReusedExchange (86)
                           +- ReusedExchange (89)


(1) Scan parquet spark_catalog.default.store_sales
Output [3]: [ss_addr_sk#1, ss_ext_sales_price#2, ss_sold_date_sk#3]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(ss_sold_date_sk#3)]
PushedFilters: [IsNotNull(ss_addr_sk)]
ReadSchema: struct<ss_addr_sk:int,ss_ext_sales_price:decimal(7,2)>

(2) ColumnarToRow [codegen id : 3]
Input [3]: [ss_addr_sk#1, ss_ext_sales_price#2, ss_sold_date_sk#3]

(3) Filter [codegen id : 3]
Input [3]: [ss_addr_sk#1, ss_ext_sales_price#2, ss_sold_date_sk#3]
Condition : isnotnull(ss_addr_sk#1)

(4) Scan parquet spark_catalog.default.date_dim
Output [3]: [d_date_sk#4, d_year#5, d_qoy#6]
Batched: true
Location [not included in comparison]/{warehouse_dir}/date_dim]
PushedFilters: [IsNotNull(d_qoy), IsNotNull(d_year), EqualTo(d_qoy,1), EqualTo(d_year,2000), IsNotNull(d_date_sk)]
ReadSchema: struct<d_date_sk:int,d_year:int,d_qoy:int>

(5) ColumnarToRow [codegen id : 1]
Input [3]: [d_date_sk#4, d_year#5, d_qoy#6]

(6) Filter [codegen id : 1]
Input [3]: [d_date_sk#4, d_year#5, d_qoy#6]
Condition : ((((isnotnull(d_qoy#6) AND isnotnull(d_year#5)) AND (d_qoy#6 = 1)) AND (d_year#5 = 2000)) AND isnotnull(d_date_sk#4))

(7) BroadcastExchange
Input [3]: [d_date_sk#4, d_year#5, d_qoy#6]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, false] as bigint)),false), [plan_id=1]

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

(9) Project [codegen id : 3]
Output [4]: [ss_addr_sk#1, ss_ext_sales_price#2, d_year#5, d_qoy#6]
Input [6]: [ss_addr_sk#1, ss_ext_sales_price#2, ss_sold_date_sk#3, d_date_sk#4, d_year#5, d_qoy#6]

(10) Scan parquet spark_catalog.default.customer_address
Output [2]: [ca_address_sk#7, ca_county#8]
Batched: true
Location [not included in comparison]/{warehouse_dir}/customer_address]
PushedFilters: [IsNotNull(ca_address_sk), IsNotNull(ca_county)]
ReadSchema: struct<ca_address_sk:int,ca_county:string>

(11) ColumnarToRow [codegen id : 2]
Input [2]: [ca_address_sk#7, ca_county#8]

(12) Filter [codegen id : 2]
Input [2]: [ca_address_sk#7, ca_county#8]
Condition : (isnotnull(ca_address_sk#7) AND isnotnull(ca_county#8))

(13) BroadcastExchange
Input [2]: [ca_address_sk#7, ca_county#8]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, false] as bigint)),false), [plan_id=2]

(14) BroadcastHashJoin [codegen id : 3]
Left keys [1]: [ss_addr_sk#1]
Right keys [1]: [ca_address_sk#7]
Join type: Inner
Join condition: None

(15) Project [codegen id : 3]
Output [4]: [ss_ext_sales_price#2, d_year#5, d_qoy#6, ca_county#8]
Input [6]: [ss_addr_sk#1, ss_ext_sales_price#2, d_year#5, d_qoy#6, ca_address_sk#7, ca_county#8]

(16) HashAggregate [codegen id : 3]
Input [4]: [ss_ext_sales_price#2, d_year#5, d_qoy#6, ca_county#8]
Keys [3]: [ca_county#8, d_qoy#6, d_year#5]
Functions [1]: [partial_sum(UnscaledValue(ss_ext_sales_price#2))]
Aggregate Attributes [1]: [sum#9]
Results [4]: [ca_county#8, d_qoy#6, d_year#5, sum#10]

(17) Exchange
Input [4]: [ca_county#8, d_qoy#6, d_year#5, sum#10]
Arguments: hashpartitioning(ca_county#8, d_qoy#6, d_year#5, 5), ENSURE_REQUIREMENTS, [plan_id=3]

(18) HashAggregate [codegen id : 24]
Input [4]: [ca_county#8, d_qoy#6, d_year#5, sum#10]
Keys [3]: [ca_county#8, d_qoy#6, d_year#5]
Functions [1]: [sum(UnscaledValue(ss_ext_sales_price#2))]
Aggregate Attributes [1]: [sum(UnscaledValue(ss_ext_sales_price#2))#11]
Results [3]: [ca_county#8, d_year#5, MakeDecimal(sum(UnscaledValue(ss_ext_sales_price#2))#11,17,2) AS store_sales#12]

(19) Scan parquet spark_catalog.default.store_sales
Output [3]: [ss_addr_sk#13, ss_ext_sales_price#14, ss_sold_date_sk#15]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(ss_sold_date_sk#15)]
PushedFilters: [IsNotNull(ss_addr_sk)]
ReadSchema: struct<ss_addr_sk:int,ss_ext_sales_price:decimal(7,2)>

(20) ColumnarToRow [codegen id : 6]
Input [3]: [ss_addr_sk#13, ss_ext_sales_price#14, ss_sold_date_sk#15]

(21) Filter [codegen id : 6]
Input [3]: [ss_addr_sk#13, ss_ext_sales_price#14, ss_sold_date_sk#15]
Condition : isnotnull(ss_addr_sk#13)

(22) Scan parquet spark_catalog.default.date_dim
Output [3]: [d_date_sk#16, d_year#17, d_qoy#18]
Batched: true
Location [not included in comparison]/{warehouse_dir}/date_dim]
PushedFilters: [IsNotNull(d_qoy), IsNotNull(d_year), EqualTo(d_qoy,2), EqualTo(d_year,2000), IsNotNull(d_date_sk)]
ReadSchema: struct<d_date_sk:int,d_year:int,d_qoy:int>

(23) ColumnarToRow [codegen id : 4]
Input [3]: [d_date_sk#16, d_year#17, d_qoy#18]

(24) Filter [codegen id : 4]
Input [3]: [d_date_sk#16, d_year#17, d_qoy#18]
Condition : ((((isnotnull(d_qoy#18) AND isnotnull(d_year#17)) AND (d_qoy#18 = 2)) AND (d_year#17 = 2000)) AND isnotnull(d_date_sk#16))

(25) BroadcastExchange
Input [3]: [d_date_sk#16, d_year#17, d_qoy#18]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, false] as bigint)),false), [plan_id=4]

(26) BroadcastHashJoin [codegen id : 6]
Left keys [1]: [ss_sold_date_sk#15]
Right keys [1]: [d_date_sk#16]
Join type: Inner
Join condition: None

(27) Project [codegen id : 6]
Output [4]: [ss_addr_sk#13, ss_ext_sales_price#14, d_year#17, d_qoy#18]
Input [6]: [ss_addr_sk#13, ss_ext_sales_price#14, ss_sold_date_sk#15, d_date_sk#16, d_year#17, d_qoy#18]

(28) ReusedExchange [Reuses operator id: 13]
Output [2]: [ca_address_sk#19, ca_county#20]

(29) BroadcastHashJoin [codegen id : 6]
Left keys [1]: [ss_addr_sk#13]
Right keys [1]: [ca_address_sk#19]
Join type: Inner
Join condition: None

(30) Project [codegen id : 6]
Output [4]: [ss_ext_sales_price#14, d_year#17, d_qoy#18, ca_county#20]
Input [6]: [ss_addr_sk#13, ss_ext_sales_price#14, d_year#17, d_qoy#18, ca_address_sk#19, ca_county#20]

(31) HashAggregate [codegen id : 6]
Input [4]: [ss_ext_sales_price#14, d_year#17, d_qoy#18, ca_county#20]
Keys [3]: [ca_county#20, d_qoy#18, d_year#17]
Functions [1]: [partial_sum(UnscaledValue(ss_ext_sales_price#14))]
Aggregate Attributes [1]: [sum#21]
Results [4]: [ca_county#20, d_qoy#18, d_year#17, sum#22]

(32) Exchange
Input [4]: [ca_county#20, d_qoy#18, d_year#17, sum#22]
Arguments: hashpartitioning(ca_county#20, d_qoy#18, d_year#17, 5), ENSURE_REQUIREMENTS, [plan_id=5]

(33) HashAggregate [codegen id : 7]
Input [4]: [ca_county#20, d_qoy#18, d_year#17, sum#22]
Keys [3]: [ca_county#20, d_qoy#18, d_year#17]
Functions [1]: [sum(UnscaledValue(ss_ext_sales_price#14))]
Aggregate Attributes [1]: [sum(UnscaledValue(ss_ext_sales_price#14))#11]
Results [2]: [ca_county#20, MakeDecimal(sum(UnscaledValue(ss_ext_sales_price#14))#11,17,2) AS store_sales#23]

(34) BroadcastExchange
Input [2]: [ca_county#20, store_sales#23]
Arguments: HashedRelationBroadcastMode(List(input[0, string, true]),false), [plan_id=6]

(35) BroadcastHashJoin [codegen id : 24]
Left keys [1]: [ca_county#8]
Right keys [1]: [ca_county#20]
Join type: Inner
Join condition: None

(36) Scan parquet spark_catalog.default.store_sales
Output [3]: [ss_addr_sk#24, ss_ext_sales_price#25, ss_sold_date_sk#26]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(ss_sold_date_sk#26)]
PushedFilters: [IsNotNull(ss_addr_sk)]
ReadSchema: struct<ss_addr_sk:int,ss_ext_sales_price:decimal(7,2)>

(37) ColumnarToRow [codegen id : 10]
Input [3]: [ss_addr_sk#24, ss_ext_sales_price#25, ss_sold_date_sk#26]

(38) Filter [codegen id : 10]
Input [3]: [ss_addr_sk#24, ss_ext_sales_price#25, ss_sold_date_sk#26]
Condition : isnotnull(ss_addr_sk#24)

(39) Scan parquet spark_catalog.default.date_dim
Output [3]: [d_date_sk#27, d_year#28, d_qoy#29]
Batched: true
Location [not included in comparison]/{warehouse_dir}/date_dim]
PushedFilters: [IsNotNull(d_qoy), IsNotNull(d_year), EqualTo(d_qoy,3), EqualTo(d_year,2000), IsNotNull(d_date_sk)]
ReadSchema: struct<d_date_sk:int,d_year:int,d_qoy:int>

(40) ColumnarToRow [codegen id : 8]
Input [3]: [d_date_sk#27, d_year#28, d_qoy#29]

(41) Filter [codegen id : 8]
Input [3]: [d_date_sk#27, d_year#28, d_qoy#29]
Condition : ((((isnotnull(d_qoy#29) AND isnotnull(d_year#28)) AND (d_qoy#29 = 3)) AND (d_year#28 = 2000)) AND isnotnull(d_date_sk#27))

(42) BroadcastExchange
Input [3]: [d_date_sk#27, d_year#28, d_qoy#29]
Arguments: HashedRelationBroadcastMode(List(cast(input[0, int, false] as bigint)),false), [plan_id=7]

(43) BroadcastHashJoin [codegen id : 10]
Left keys [1]: [ss_sold_date_sk#26]
Right keys [1]: [d_date_sk#27]
Join type: Inner
Join condition: None

(44) Project [codegen id : 10]
Output [4]: [ss_addr_sk#24, ss_ext_sales_price#25, d_year#28, d_qoy#29]
Input [6]: [ss_addr_sk#24, ss_ext_sales_price#25, ss_sold_date_sk#26, d_date_sk#27, d_year#28, d_qoy#29]

(45) ReusedExchange [Reuses operator id: 13]
Output [2]: [ca_address_sk#30, ca_county#31]

(46) BroadcastHashJoin [codegen id : 10]
Left keys [1]: [ss_addr_sk#24]
Right keys [1]: [ca_address_sk#30]
Join type: Inner
Join condition: None

(47) Project [codegen id : 10]
Output [4]: [ss_ext_sales_price#25, d_year#28, d_qoy#29, ca_county#31]
Input [6]: [ss_addr_sk#24, ss_ext_sales_price#25, d_year#28, d_qoy#29, ca_address_sk#30, ca_county#31]

(48) HashAggregate [codegen id : 10]
Input [4]: [ss_ext_sales_price#25, d_year#28, d_qoy#29, ca_county#31]
Keys [3]: [ca_county#31, d_qoy#29, d_year#28]
Functions [1]: [partial_sum(UnscaledValue(ss_ext_sales_price#25))]
Aggregate Attributes [1]: [sum#32]
Results [4]: [ca_county#31, d_qoy#29, d_year#28, sum#33]

(49) Exchange
Input [4]: [ca_county#31, d_qoy#29, d_year#28, sum#33]
Arguments: hashpartitioning(ca_county#31, d_qoy#29, d_year#28, 5), ENSURE_REQUIREMENTS, [plan_id=8]

(50) HashAggregate [codegen id : 11]
Input [4]: [ca_county#31, d_qoy#29, d_year#28, sum#33]
Keys [3]: [ca_county#31, d_qoy#29, d_year#28]
Functions [1]: [sum(UnscaledValue(ss_ext_sales_price#25))]
Aggregate Attributes [1]: [sum(UnscaledValue(ss_ext_sales_price#25))#11]
Results [2]: [ca_county#31, MakeDecimal(sum(UnscaledValue(ss_ext_sales_price#25))#11,17,2) AS store_sales#34]

(51) BroadcastExchange
Input [2]: [ca_county#31, store_sales#34]
Arguments: HashedRelationBroadcastMode(List(input[0, string, true]),false), [plan_id=9]

(52) BroadcastHashJoin [codegen id : 24]
Left keys [1]: [ca_county#20]
Right keys [1]: [ca_county#31]
Join type: Inner
Join condition: None

(53) Project [codegen id : 24]
Output [5]: [ca_county#8, d_year#5, store_sales#12, store_sales#23, store_sales#34]
Input [7]: [ca_county#8, d_year#5, store_sales#12, ca_county#20, store_sales#23, ca_county#31, store_sales#34]

(54) Scan parquet spark_catalog.default.web_sales
Output [3]: [ws_bill_addr_sk#35, ws_ext_sales_price#36, ws_sold_date_sk#37]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(ws_sold_date_sk#37)]
PushedFilters: [IsNotNull(ws_bill_addr_sk)]
ReadSchema: struct<ws_bill_addr_sk:int,ws_ext_sales_price:decimal(7,2)>

(55) ColumnarToRow [codegen id : 14]
Input [3]: [ws_bill_addr_sk#35, ws_ext_sales_price#36, ws_sold_date_sk#37]

(56) Filter [codegen id : 14]
Input [3]: [ws_bill_addr_sk#35, ws_ext_sales_price#36, ws_sold_date_sk#37]
Condition : isnotnull(ws_bill_addr_sk#35)

(57) ReusedExchange [Reuses operator id: 7]
Output [3]: [d_date_sk#38, d_year#39, d_qoy#40]

(58) BroadcastHashJoin [codegen id : 14]
Left keys [1]: [ws_sold_date_sk#37]
Right keys [1]: [d_date_sk#38]
Join type: Inner
Join condition: None

(59) Project [codegen id : 14]
Output [4]: [ws_bill_addr_sk#35, ws_ext_sales_price#36, d_year#39, d_qoy#40]
Input [6]: [ws_bill_addr_sk#35, ws_ext_sales_price#36, ws_sold_date_sk#37, d_date_sk#38, d_year#39, d_qoy#40]

(60) ReusedExchange [Reuses operator id: 13]
Output [2]: [ca_address_sk#41, ca_county#42]

(61) BroadcastHashJoin [codegen id : 14]
Left keys [1]: [ws_bill_addr_sk#35]
Right keys [1]: [ca_address_sk#41]
Join type: Inner
Join condition: None

(62) Project [codegen id : 14]
Output [4]: [ws_ext_sales_price#36, d_year#39, d_qoy#40, ca_county#42]
Input [6]: [ws_bill_addr_sk#35, ws_ext_sales_price#36, d_year#39, d_qoy#40, ca_address_sk#41, ca_county#42]

(63) HashAggregate [codegen id : 14]
Input [4]: [ws_ext_sales_price#36, d_year#39, d_qoy#40, ca_county#42]
Keys [3]: [ca_county#42, d_qoy#40, d_year#39]
Functions [1]: [partial_sum(UnscaledValue(ws_ext_sales_price#36))]
Aggregate Attributes [1]: [sum#43]
Results [4]: [ca_county#42, d_qoy#40, d_year#39, sum#44]

(64) Exchange
Input [4]: [ca_county#42, d_qoy#40, d_year#39, sum#44]
Arguments: hashpartitioning(ca_county#42, d_qoy#40, d_year#39, 5), ENSURE_REQUIREMENTS, [plan_id=10]

(65) HashAggregate [codegen id : 15]
Input [4]: [ca_county#42, d_qoy#40, d_year#39, sum#44]
Keys [3]: [ca_county#42, d_qoy#40, d_year#39]
Functions [1]: [sum(UnscaledValue(ws_ext_sales_price#36))]
Aggregate Attributes [1]: [sum(UnscaledValue(ws_ext_sales_price#36))#45]
Results [2]: [ca_county#42, MakeDecimal(sum(UnscaledValue(ws_ext_sales_price#36))#45,17,2) AS web_sales#46]

(66) BroadcastExchange
Input [2]: [ca_county#42, web_sales#46]
Arguments: HashedRelationBroadcastMode(List(input[0, string, true]),false), [plan_id=11]

(67) BroadcastHashJoin [codegen id : 24]
Left keys [1]: [ca_county#8]
Right keys [1]: [ca_county#42]
Join type: Inner
Join condition: None

(68) Scan parquet spark_catalog.default.web_sales
Output [3]: [ws_bill_addr_sk#47, ws_ext_sales_price#48, ws_sold_date_sk#49]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(ws_sold_date_sk#49)]
PushedFilters: [IsNotNull(ws_bill_addr_sk)]
ReadSchema: struct<ws_bill_addr_sk:int,ws_ext_sales_price:decimal(7,2)>

(69) ColumnarToRow [codegen id : 18]
Input [3]: [ws_bill_addr_sk#47, ws_ext_sales_price#48, ws_sold_date_sk#49]

(70) Filter [codegen id : 18]
Input [3]: [ws_bill_addr_sk#47, ws_ext_sales_price#48, ws_sold_date_sk#49]
Condition : isnotnull(ws_bill_addr_sk#47)

(71) ReusedExchange [Reuses operator id: 25]
Output [3]: [d_date_sk#50, d_year#51, d_qoy#52]

(72) BroadcastHashJoin [codegen id : 18]
Left keys [1]: [ws_sold_date_sk#49]
Right keys [1]: [d_date_sk#50]
Join type: Inner
Join condition: None

(73) Project [codegen id : 18]
Output [4]: [ws_bill_addr_sk#47, ws_ext_sales_price#48, d_year#51, d_qoy#52]
Input [6]: [ws_bill_addr_sk#47, ws_ext_sales_price#48, ws_sold_date_sk#49, d_date_sk#50, d_year#51, d_qoy#52]

(74) ReusedExchange [Reuses operator id: 13]
Output [2]: [ca_address_sk#53, ca_county#54]

(75) BroadcastHashJoin [codegen id : 18]
Left keys [1]: [ws_bill_addr_sk#47]
Right keys [1]: [ca_address_sk#53]
Join type: Inner
Join condition: None

(76) Project [codegen id : 18]
Output [4]: [ws_ext_sales_price#48, d_year#51, d_qoy#52, ca_county#54]
Input [6]: [ws_bill_addr_sk#47, ws_ext_sales_price#48, d_year#51, d_qoy#52, ca_address_sk#53, ca_county#54]

(77) HashAggregate [codegen id : 18]
Input [4]: [ws_ext_sales_price#48, d_year#51, d_qoy#52, ca_county#54]
Keys [3]: [ca_county#54, d_qoy#52, d_year#51]
Functions [1]: [partial_sum(UnscaledValue(ws_ext_sales_price#48))]
Aggregate Attributes [1]: [sum#55]
Results [4]: [ca_county#54, d_qoy#52, d_year#51, sum#56]

(78) Exchange
Input [4]: [ca_county#54, d_qoy#52, d_year#51, sum#56]
Arguments: hashpartitioning(ca_county#54, d_qoy#52, d_year#51, 5), ENSURE_REQUIREMENTS, [plan_id=12]

(79) HashAggregate [codegen id : 19]
Input [4]: [ca_county#54, d_qoy#52, d_year#51, sum#56]
Keys [3]: [ca_county#54, d_qoy#52, d_year#51]
Functions [1]: [sum(UnscaledValue(ws_ext_sales_price#48))]
Aggregate Attributes [1]: [sum(UnscaledValue(ws_ext_sales_price#48))#45]
Results [2]: [ca_county#54, MakeDecimal(sum(UnscaledValue(ws_ext_sales_price#48))#45,17,2) AS web_sales#57]

(80) BroadcastExchange
Input [2]: [ca_county#54, web_sales#57]
Arguments: HashedRelationBroadcastMode(List(input[0, string, true]),false), [plan_id=13]

(81) BroadcastHashJoin [codegen id : 24]
Left keys [1]: [ca_county#42]
Right keys [1]: [ca_county#54]
Join type: Inner
Join condition: (CASE WHEN (web_sales#46 > 0.00) THEN (web_sales#57 / web_sales#46) END > CASE WHEN (store_sales#12 > 0.00) THEN (store_sales#23 / store_sales#12) END)

(82) Project [codegen id : 24]
Output [8]: [ca_county#8, d_year#5, store_sales#12, store_sales#23, store_sales#34, ca_county#42, web_sales#46, web_sales#57]
Input [9]: [ca_county#8, d_year#5, store_sales#12, store_sales#23, store_sales#34, ca_county#42, web_sales#46, ca_county#54, web_sales#57]

(83) Scan parquet spark_catalog.default.web_sales
Output [3]: [ws_bill_addr_sk#58, ws_ext_sales_price#59, ws_sold_date_sk#60]
Batched: true
Location: InMemoryFileIndex []
PartitionFilters: [isnotnull(ws_sold_date_sk#60)]
PushedFilters: [IsNotNull(ws_bill_addr_sk)]
ReadSchema: struct<ws_bill_addr_sk:int,ws_ext_sales_price:decimal(7,2)>

(84) ColumnarToRow [codegen id : 22]
Input [3]: [ws_bill_addr_sk#58, ws_ext_sales_price#59, ws_sold_date_sk#60]

(85) Filter [codegen id : 22]
Input [3]: [ws_bill_addr_sk#58, ws_ext_sales_price#59, ws_sold_date_sk#60]
Condition : isnotnull(ws_bill_addr_sk#58)

(86) ReusedExchange [Reuses operator id: 42]
Output [3]: [d_date_sk#61, d_year#62, d_qoy#63]

(87) BroadcastHashJoin [codegen id : 22]
Left keys [1]: [ws_sold_date_sk#60]
Right keys [1]: [d_date_sk#61]
Join type: Inner
Join condition: None

(88) Project [codegen id : 22]
Output [4]: [ws_bill_addr_sk#58, ws_ext_sales_price#59, d_year#62, d_qoy#63]
Input [6]: [ws_bill_addr_sk#58, ws_ext_sales_price#59, ws_sold_date_sk#60, d_date_sk#61, d_year#62, d_qoy#63]

(89) ReusedExchange [Reuses operator id: 13]
Output [2]: [ca_address_sk#64, ca_county#65]

(90) BroadcastHashJoin [codegen id : 22]
Left keys [1]: [ws_bill_addr_sk#58]
Right keys [1]: [ca_address_sk#64]
Join type: Inner
Join condition: None

(91) Project [codegen id : 22]
Output [4]: [ws_ext_sales_price#59, d_year#62, d_qoy#63, ca_county#65]
Input [6]: [ws_bill_addr_sk#58, ws_ext_sales_price#59, d_year#62, d_qoy#63, ca_address_sk#64, ca_county#65]

(92) HashAggregate [codegen id : 22]
Input [4]: [ws_ext_sales_price#59, d_year#62, d_qoy#63, ca_county#65]
Keys [3]: [ca_county#65, d_qoy#63, d_year#62]
Functions [1]: [partial_sum(UnscaledValue(ws_ext_sales_price#59))]
Aggregate Attributes [1]: [sum#66]
Results [4]: [ca_county#65, d_qoy#63, d_year#62, sum#67]

(93) Exchange
Input [4]: [ca_county#65, d_qoy#63, d_year#62, sum#67]
Arguments: hashpartitioning(ca_county#65, d_qoy#63, d_year#62, 5), ENSURE_REQUIREMENTS, [plan_id=14]

(94) HashAggregate [codegen id : 23]
Input [4]: [ca_county#65, d_qoy#63, d_year#62, sum#67]
Keys [3]: [ca_county#65, d_qoy#63, d_year#62]
Functions [1]: [sum(UnscaledValue(ws_ext_sales_price#59))]
Aggregate Attributes [1]: [sum(UnscaledValue(ws_ext_sales_price#59))#45]
Results [2]: [ca_county#65, MakeDecimal(sum(UnscaledValue(ws_ext_sales_price#59))#45,17,2) AS web_sales#68]

(95) BroadcastExchange
Input [2]: [ca_county#65, web_sales#68]
Arguments: HashedRelationBroadcastMode(List(input[0, string, true]),false), [plan_id=15]

(96) BroadcastHashJoin [codegen id : 24]
Left keys [1]: [ca_county#42]
Right keys [1]: [ca_county#65]
Join type: Inner
Join condition: (CASE WHEN (web_sales#57 > 0.00) THEN (web_sales#68 / web_sales#57) END > CASE WHEN (store_sales#23 > 0.00) THEN (store_sales#34 / store_sales#23) END)

(97) Project [codegen id : 24]
Output [6]: [ca_county#8, d_year#5, (web_sales#57 / web_sales#46) AS web_q1_q2_increase#69, (store_sales#23 / store_sales#12) AS store_q1_q2_increase#70, (web_sales#68 / web_sales#57) AS web_q2_q3_increase#71, (store_sales#34 / store_sales#23) AS store_q2_q3_increase#72]
Input [10]: [ca_county#8, d_year#5, store_sales#12, store_sales#23, store_sales#34, ca_county#42, web_sales#46, web_sales#57, ca_county#65, web_sales#68]

(98) Exchange
Input [6]: [ca_county#8, d_year#5, web_q1_q2_increase#69, store_q1_q2_increase#70, web_q2_q3_increase#71, store_q2_q3_increase#72]
Arguments: rangepartitioning(ca_county#8 ASC NULLS FIRST, 5), ENSURE_REQUIREMENTS, [plan_id=16]

(99) Sort [codegen id : 25]
Input [6]: [ca_county#8, d_year#5, web_q1_q2_increase#69, store_q1_q2_increase#70, web_q2_q3_increase#71, store_q2_q3_increase#72]
Arguments: [ca_county#8 ASC NULLS FIRST], true, 0

