== Physical Plan ==
TakeOrderedAndProject (37)
+- * Project (36)
   +- * BroadcastHashJoin Inner BuildLeft (35)
      :- BroadcastExchange (30)
      :  +- * Project (29)
      :     +- * BroadcastHashJoin Inner BuildLeft (28)
      :        :- BroadcastExchange (24)
      :        :  +- * Project (23)
      :        :     +- * BroadcastHashJoin Inner BuildRight (22)
      :        :        :- * Project (10)
      :        :        :  +- * BroadcastHashJoin Inner BuildRight (9)
      :        :        :     :- * Filter (3)
      :        :        :     :  +- * ColumnarToRow (2)
      :        :        :     :     +- Scan parquet spark_catalog.default.customer (1)
      :        :        :     +- BroadcastExchange (8)
      :        :        :        +- * Project (7)
      :        :        :           +- * Filter (6)
      :        :        :              +- * ColumnarToRow (5)
      :        :        :                 +- Scan parquet spark_catalog.default.customer_address (4)
      :        :        +- BroadcastExchange (21)
      :        :           +- * Project (20)
      :        :              +- * BroadcastHashJoin Inner BuildRight (19)
      :        :                 :- * Filter (13)
      :        :                 :  +- * ColumnarToRow (12)
      :        :                 :     +- Scan parquet spark_catalog.default.household_demographics (11)
      :        :                 +- BroadcastExchange (18)
      :        :                    +- * Project (17)
      :        :                       +- * Filter (16)
      :        :                          +- * ColumnarToRow (15)
      :        :                             +- Scan parquet spark_catalog.default.income_band (14)
      :        +- * Filter (27)
      :           +- * ColumnarToRow (26)
      :              +- Scan parquet spark_catalog.default.customer_demographics (25)
      +- * Project (34)
         +- * Filter (33)
            +- * ColumnarToRow (32)
               +- Scan parquet spark_catalog.default.store_returns (31)


(1) Scan parquet spark_catalog.default.customer
Output [6]: [c_customer_id#1, c_current_cdemo_sk#2, c_current_hdemo_sk#3, c_current_addr_sk#4, c_first_name#5, c_last_name#6]
Batched: true
Location [not included in comparison]/{warehouse_dir}/customer]
PushedFilters: [IsNotNull(c_current_addr_sk), IsNotNull(c_current_cdemo_sk), IsNotNull(c_current_hdemo_sk)]
ReadSchema: struct<c_customer_id:string,c_current_cdemo_sk:int,c_current_hdemo_sk:int,c_current_addr_sk:int,c_first_name:string,c_last_name:string>

(2) ColumnarToRow [codegen id : 4]
Input [6]: [c_customer_id#1, c_current_cdemo_sk#2, c_current_hdemo_sk#3, c_current_addr_sk#4, c_first_name#5, c_last_name#6]

(3) Filter [codegen id : 4]
Input [6]: [c_customer_id#1, c_current_cdemo_sk#2, c_current_hdemo_sk#3, c_current_addr_sk#4, c_first_name#5, c_last_name#6]
Condition : ((isnotnull(c_current_addr_sk#4) AND isnotnull(c_current_cdemo_sk#2)) AND isnotnull(c_current_hdemo_sk#3))

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

(5) ColumnarToRow [codegen id : 1]
Input [2]: [ca_address_sk#7, ca_city#8]

(6) Filter [codegen id : 1]
Input [2]: [ca_address_sk#7, ca_city#8]
Condition : ((isnotnull(ca_city#8) AND (ca_city#8 = Edgewood)) AND isnotnull(ca_address_sk#7))

(7) Project [codegen id : 1]
Output [1]: [ca_address_sk#7]
Input [2]: [ca_address_sk#7, ca_city#8]

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

(9) BroadcastHashJoin [codegen id : 4]
Left keys [1]: [c_current_addr_sk#4]
Right keys [1]: [ca_address_sk#7]
Join type: Inner
Join condition: None

(10) Project [codegen id : 4]
Output [5]: [c_customer_id#1, c_current_cdemo_sk#2, c_current_hdemo_sk#3, c_first_name#5, c_last_name#6]
Input [7]: [c_customer_id#1, c_current_cdemo_sk#2, c_current_hdemo_sk#3, c_current_addr_sk#4, c_first_name#5, c_last_name#6, ca_address_sk#7]

(11) Scan parquet spark_catalog.default.household_demographics
Output [2]: [hd_demo_sk#9, hd_income_band_sk#10]
Batched: true
Location [not included in comparison]/{warehouse_dir}/household_demographics]
PushedFilters: [IsNotNull(hd_demo_sk), IsNotNull(hd_income_band_sk)]
ReadSchema: struct<hd_demo_sk:int,hd_income_band_sk:int>

(12) ColumnarToRow [codegen id : 3]
Input [2]: [hd_demo_sk#9, hd_income_band_sk#10]

(13) Filter [codegen id : 3]
Input [2]: [hd_demo_sk#9, hd_income_band_sk#10]
Condition : (isnotnull(hd_demo_sk#9) AND isnotnull(hd_income_band_sk#10))

(14) Scan parquet spark_catalog.default.income_band
Output [3]: [ib_income_band_sk#11, ib_lower_bound#12, ib_upper_bound#13]
Batched: true
Location [not included in comparison]/{warehouse_dir}/income_band]
PushedFilters: [IsNotNull(ib_lower_bound), IsNotNull(ib_upper_bound), GreaterThanOrEqual(ib_lower_bound,38128), LessThanOrEqual(ib_upper_bound,88128), IsNotNull(ib_income_band_sk)]
ReadSchema: struct<ib_income_band_sk:int,ib_lower_bound:int,ib_upper_bound:int>

(15) ColumnarToRow [codegen id : 2]
Input [3]: [ib_income_band_sk#11, ib_lower_bound#12, ib_upper_bound#13]

(16) Filter [codegen id : 2]
Input [3]: [ib_income_band_sk#11, ib_lower_bound#12, ib_upper_bound#13]
Condition : ((((isnotnull(ib_lower_bound#12) AND isnotnull(ib_upper_bound#13)) AND (ib_lower_bound#12 >= 38128)) AND (ib_upper_bound#13 <= 88128)) AND isnotnull(ib_income_band_sk#11))

(17) Project [codegen id : 2]
Output [1]: [ib_income_band_sk#11]
Input [3]: [ib_income_band_sk#11, ib_lower_bound#12, ib_upper_bound#13]

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

(19) BroadcastHashJoin [codegen id : 3]
Left keys [1]: [hd_income_band_sk#10]
Right keys [1]: [ib_income_band_sk#11]
Join type: Inner
Join condition: None

(20) Project [codegen id : 3]
Output [1]: [hd_demo_sk#9]
Input [3]: [hd_demo_sk#9, hd_income_band_sk#10, ib_income_band_sk#11]

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

(22) BroadcastHashJoin [codegen id : 4]
Left keys [1]: [c_current_hdemo_sk#3]
Right keys [1]: [hd_demo_sk#9]
Join type: Inner
Join condition: None

(23) Project [codegen id : 4]
Output [4]: [c_customer_id#1, c_current_cdemo_sk#2, c_first_name#5, c_last_name#6]
Input [6]: [c_customer_id#1, c_current_cdemo_sk#2, c_current_hdemo_sk#3, c_first_name#5, c_last_name#6, hd_demo_sk#9]

(24) BroadcastExchange
Input [4]: [c_customer_id#1, c_current_cdemo_sk#2, c_first_name#5, c_last_name#6]
Arguments: HashedRelationBroadcastMode(List(cast(input[1, int, true] as bigint)),false), [plan_id=4]

(25) Scan parquet spark_catalog.default.customer_demographics
Output [1]: [cd_demo_sk#14]
Batched: true
Location [not included in comparison]/{warehouse_dir}/customer_demographics]
PushedFilters: [IsNotNull(cd_demo_sk)]
ReadSchema: struct<cd_demo_sk:int>

(26) ColumnarToRow
Input [1]: [cd_demo_sk#14]

(27) Filter
Input [1]: [cd_demo_sk#14]
Condition : isnotnull(cd_demo_sk#14)

(28) BroadcastHashJoin [codegen id : 5]
Left keys [1]: [c_current_cdemo_sk#2]
Right keys [1]: [cd_demo_sk#14]
Join type: Inner
Join condition: None

(29) Project [codegen id : 5]
Output [4]: [c_customer_id#1, c_first_name#5, c_last_name#6, cd_demo_sk#14]
Input [5]: [c_customer_id#1, c_current_cdemo_sk#2, c_first_name#5, c_last_name#6, cd_demo_sk#14]

(30) BroadcastExchange
Input [4]: [c_customer_id#1, c_first_name#5, c_last_name#6, cd_demo_sk#14]
Arguments: HashedRelationBroadcastMode(List(cast(input[3, int, true] as bigint)),false), [plan_id=5]

(31) Scan parquet spark_catalog.default.store_returns
Output [2]: [sr_cdemo_sk#15, sr_returned_date_sk#16]
Batched: true
Location [not included in comparison]/{warehouse_dir}/store_returns]
PushedFilters: [IsNotNull(sr_cdemo_sk)]
ReadSchema: struct<sr_cdemo_sk:int>

(32) ColumnarToRow
Input [2]: [sr_cdemo_sk#15, sr_returned_date_sk#16]

(33) Filter
Input [2]: [sr_cdemo_sk#15, sr_returned_date_sk#16]
Condition : isnotnull(sr_cdemo_sk#15)

(34) Project
Output [1]: [sr_cdemo_sk#15]
Input [2]: [sr_cdemo_sk#15, sr_returned_date_sk#16]

(35) BroadcastHashJoin [codegen id : 6]
Left keys [1]: [cd_demo_sk#14]
Right keys [1]: [sr_cdemo_sk#15]
Join type: Inner
Join condition: None

(36) Project [codegen id : 6]
Output [3]: [c_customer_id#1 AS customer_id#17, concat(c_last_name#6, , , c_first_name#5) AS customername#18, c_customer_id#1]
Input [5]: [c_customer_id#1, c_first_name#5, c_last_name#6, cd_demo_sk#14, sr_cdemo_sk#15]

(37) TakeOrderedAndProject
Input [3]: [customer_id#17, customername#18, c_customer_id#1]
Arguments: 100, [c_customer_id#1 ASC NULLS FIRST], [customer_id#17, customername#18]

