== Physical Plan ==
AdaptiveSparkPlan (69)
+- == Final Plan ==
   NativeTakeOrdered (44)
   +- NativeProject (43)
      +- NativeHashAggregate (42)
         +- InputAdapter (41)
            +- AQEShuffleRead (40)
               +- ShuffleQueryStage (39), Statistics(X)
                  +- NativeShuffleExchange (38)
                     +- NativeHashAggregate (37)
                        +- NativeProject (36)
                           +- NativeProject (35)
                              +- NativeSortMergeJoin Inner (34)
                                 :- NativeSort (24)
                                 :  +- InputAdapter (23)
                                 :     +- AQEShuffleRead (22)
                                 :        +- ShuffleQueryStage (21), Statistics(X)
                                 :           +- NativeShuffleExchange (20)
                                 :              +- NativeProject (19)
                                 :                 +- NativeSortMergeJoin Inner (18)
                                 :                    :- NativeSort (9)
                                 :                    :  +- InputAdapter (8)
                                 :                    :     +- AQEShuffleRead (7)
                                 :                    :        +- ShuffleQueryStage (6), Statistics(X)
                                 :                    :           +- NativeShuffleExchange (5)
                                 :                    :              +- NativeProject (4)
                                 :                    :                 +- NativeFilter (3)
                                 :                    :                    +- InputAdapter (2)
                                 :                    :                       +- NativeParquetScan  (1)
                                 :                    +- NativeSort (17)
                                 :                       +- InputAdapter (16)
                                 :                          +- AQEShuffleRead (15)
                                 :                             +- ShuffleQueryStage (14), Statistics(X)
                                 :                                +- NativeShuffleExchange (13)
                                 :                                   +- NativeFilter (12)
                                 :                                      +- InputAdapter (11)
                                 :                                         +- NativeParquetScan  (10)
                                 +- NativeSort (33)
                                    +- InputAdapter (32)
                                       +- AQEShuffleRead (31)
                                          +- ShuffleQueryStage (30), Statistics(X)
                                             +- NativeShuffleExchange (29)
                                                +- NativeProject (28)
                                                   +- NativeFilter (27)
                                                      +- InputAdapter (26)
                                                         +- NativeParquetScan  (25)
+- == Initial Plan ==
   TakeOrderedAndProject (68)
   +- HashAggregate (67)
      +- Exchange (66)
         +- HashAggregate (65)
            +- Project (64)
               +- SortMergeJoin Inner (63)
                  :- Sort (57)
                  :  +- Exchange (56)
                  :     +- Project (55)
                  :        +- SortMergeJoin Inner (54)
                  :           :- Sort (49)
                  :           :  +- Exchange (48)
                  :           :     +- Project (47)
                  :           :        +- Filter (46)
                  :           :           +- Scan parquet (45)
                  :           +- Sort (53)
                  :              +- Exchange (52)
                  :                 +- Filter (51)
                  :                    +- Scan parquet (50)
                  +- Sort (62)
                     +- Exchange (61)
                        +- Project (60)
                           +- Filter (59)
                              +- Scan parquet (58)


(45) Scan parquet
Output [3]: [d_date_sk#1, d_year#2, d_moy#3]
Batched: true
Location: InMemoryFileIndex [file:/<warehouse_dir>]
PushedFilters: [IsNotNull(d_moy), IsNotNull(d_year), EqualTo(d_moy,11), EqualTo(d_year,2000), IsNotNull(d_date_sk)]
ReadSchema: struct<d_date_sk:int,d_year:int,d_moy:int>

(2) InputAdapter
Input [3]: [d_date_sk#1, d_year#2, d_moy#3]
Arguments: [#1, #2, #3]

(3) NativeFilter
Input [3]: [#1#1, #2#2, #3#3]
Condition : ((((isnotnull(d_moy#3) AND isnotnull(d_year#2)) AND (d_moy#3 = 11)) AND (d_year#2 = 2000)) AND isnotnull(d_date_sk#1))

(4) NativeProject
Output [2]: [d_date_sk#1, d_year#2]
Input [3]: [#1#1, #2#2, #3#3]

(5) NativeShuffleExchange
Input [2]: [d_date_sk#1, d_year#2]
Arguments: hashpartitioning(d_date_sk#1, 100), ENSURE_REQUIREMENTS, [plan_id=1]

(6) ShuffleQueryStage
Output [2]: [d_date_sk#1, d_year#2]
Arguments: X

(7) AQEShuffleRead
Input [2]: [d_date_sk#1, d_year#2]
Arguments: coalesced

(8) InputAdapter
Input [2]: [d_date_sk#1, d_year#2]

(9) NativeSort
Input [2]: [d_date_sk#1, d_year#2]
Arguments: [d_date_sk#1 ASC NULLS FIRST], false

(50) Scan parquet
Output [3]: [ss_sold_date_sk#4, ss_item_sk#5, ss_ext_sales_price#6]
Batched: true
Location: InMemoryFileIndex [file:/<warehouse_dir>]
PushedFilters: [IsNotNull(ss_sold_date_sk), IsNotNull(ss_item_sk)]
ReadSchema: struct<ss_sold_date_sk:int,ss_item_sk:int,ss_ext_sales_price:decimal(7,2)>

(11) InputAdapter
Input [3]: [ss_sold_date_sk#4, ss_item_sk#5, ss_ext_sales_price#6]
Arguments: [#4, #5, #6]

(12) NativeFilter
Input [3]: [#4#4, #5#5, #6#6]
Condition : (isnotnull(ss_sold_date_sk#4) AND isnotnull(ss_item_sk#5))

(13) NativeShuffleExchange
Input [3]: [#4#4, #5#5, #6#6]
Arguments: hashpartitioning(ss_sold_date_sk#4, 100), ENSURE_REQUIREMENTS, [plan_id=2]

(14) ShuffleQueryStage
Output [3]: [#4#4, #5#5, #6#6]
Arguments: X

(15) AQEShuffleRead
Input [3]: [#4#4, #5#5, #6#6]
Arguments: coalesced

(16) InputAdapter
Input [3]: [#4#4, #5#5, #6#6]

(17) NativeSort
Input [3]: [#4#4, #5#5, #6#6]
Arguments: [ss_sold_date_sk#4 ASC NULLS FIRST], false

(18) NativeSortMergeJoin
Left keys [1]: [d_date_sk#1]
Right keys [1]: [ss_sold_date_sk#4]
Join type: Inner
Join condition: None

(19) NativeProject
Output [3]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6]
Input [5]: [d_date_sk#1, d_year#2, #4#4, #5#5, #6#6]

(20) NativeShuffleExchange
Input [3]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6]
Arguments: hashpartitioning(ss_item_sk#5, 100), ENSURE_REQUIREMENTS, [plan_id=3]

(21) ShuffleQueryStage
Output [3]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6]
Arguments: X

(22) AQEShuffleRead
Input [3]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6]
Arguments: coalesced

(23) InputAdapter
Input [3]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6]

(24) NativeSort
Input [3]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6]
Arguments: [ss_item_sk#5 ASC NULLS FIRST], false

(58) Scan parquet
Output [4]: [i_item_sk#7, i_category_id#8, i_category#9, i_manager_id#10]
Batched: true
Location: InMemoryFileIndex [file:/<warehouse_dir>]
PushedFilters: [IsNotNull(i_manager_id), EqualTo(i_manager_id,1), IsNotNull(i_item_sk)]
ReadSchema: struct<i_item_sk:int,i_category_id:int,i_category:string,i_manager_id:int>

(26) InputAdapter
Input [4]: [i_item_sk#7, i_category_id#8, i_category#9, i_manager_id#10]
Arguments: [#7, #8, #9, #10]

(27) NativeFilter
Input [4]: [#7#7, #8#8, #9#9, #10#10]
Condition : ((isnotnull(i_manager_id#10) AND (i_manager_id#10 = 1)) AND isnotnull(i_item_sk#7))

(28) NativeProject
Output [3]: [i_item_sk#7, i_category_id#8, i_category#9]
Input [4]: [#7#7, #8#8, #9#9, #10#10]

(29) NativeShuffleExchange
Input [3]: [i_item_sk#7, i_category_id#8, i_category#9]
Arguments: hashpartitioning(i_item_sk#7, 100), ENSURE_REQUIREMENTS, [plan_id=4]

(30) ShuffleQueryStage
Output [3]: [i_item_sk#7, i_category_id#8, i_category#9]
Arguments: X

(31) AQEShuffleRead
Input [3]: [i_item_sk#7, i_category_id#8, i_category#9]
Arguments: coalesced

(32) InputAdapter
Input [3]: [i_item_sk#7, i_category_id#8, i_category#9]

(33) NativeSort
Input [3]: [i_item_sk#7, i_category_id#8, i_category#9]
Arguments: [i_item_sk#7 ASC NULLS FIRST], false

(34) NativeSortMergeJoin
Left keys [1]: [ss_item_sk#5]
Right keys [1]: [i_item_sk#7]
Join type: Inner
Join condition: None

(35) NativeProject
Output [4]: [d_year#2, ss_ext_sales_price#6, i_category_id#8, i_category#9]
Input [6]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6, i_item_sk#7, i_category_id#8, i_category#9]

(36) NativeProject
Output [4]: [d_year#2 AS d_year#2, i_category_id#8 AS i_category_id#8, i_category#9 AS i_category#9, UnscaledValue(ss_ext_sales_price#6) AS _c3#11]
Input [4]: [d_year#2, ss_ext_sales_price#6, i_category_id#8, i_category#9]

(37) NativeHashAggregate
Input [4]: [d_year#2, i_category_id#8, i_category#9, _c3#11]
Keys [3]: [d_year#2, i_category_id#8, i_category#9]
Functions [1]: [partial_sum(_c3#11)]
Aggregate Attributes [1]: [sum#12]
Results [4]: [d_year#2, i_category_id#8, i_category#9, #13]

(38) NativeShuffleExchange
Input [4]: [d_year#2, i_category_id#8, i_category#9, #13]
Arguments: hashpartitioning(d_year#2, i_category_id#8, i_category#9, 100), ENSURE_REQUIREMENTS, [plan_id=5]

(39) ShuffleQueryStage
Output [4]: [d_year#2, i_category_id#8, i_category#9, #13]
Arguments: X

(40) AQEShuffleRead
Input [4]: [d_year#2, i_category_id#8, i_category#9, #13]
Arguments: coalesced

(41) InputAdapter
Input [4]: [d_year#2, i_category_id#8, i_category#9, #13]

(42) NativeHashAggregate
Input [4]: [d_year#2, i_category_id#8, i_category#9, #13]
Keys [3]: [d_year#2, i_category_id#8, i_category#9]
Functions [1]: [sum(UnscaledValue(ss_ext_sales_price#6))]
Aggregate Attributes [1]: [sum(UnscaledValue(ss_ext_sales_price#6))#14]
Results [4]: [d_year#2, i_category_id#8, i_category#9, sum(UnscaledValue(ss_ext_sales_price#6))#14]

(43) NativeProject
Output [4]: [d_year#2, i_category_id#8, i_category#9, MakeDecimal(sum(UnscaledValue(ss_ext_sales_price#6))#14,17,2) AS sum(ss_ext_sales_price)#15]
Input [4]: [d_year#2, i_category_id#8, i_category#9, sum(UnscaledValue(ss_ext_sales_price#6))#14]

(44) NativeTakeOrdered
Input [4]: [d_year#2, i_category_id#8, i_category#9, sum(ss_ext_sales_price)#15]
Arguments: X, X, [sum(ss_ext_sales_price)#15 DESC NULLS LAST, d_year#2 ASC NULLS FIRST, i_category_id#8 ASC NULLS FIRST, i_category#9 ASC NULLS FIRST]

(45) Scan parquet
Output [3]: [d_date_sk#1, d_year#2, d_moy#3]
Batched: true
Location: InMemoryFileIndex [file:/<warehouse_dir>]
PushedFilters: [IsNotNull(d_moy), IsNotNull(d_year), EqualTo(d_moy,11), EqualTo(d_year,2000), IsNotNull(d_date_sk)]
ReadSchema: struct<d_date_sk:int,d_year:int,d_moy:int>

(46) Filter
Input [3]: [d_date_sk#1, d_year#2, d_moy#3]
Condition : ((((isnotnull(d_moy#3) AND isnotnull(d_year#2)) AND (d_moy#3 = 11)) AND (d_year#2 = 2000)) AND isnotnull(d_date_sk#1))

(47) Project
Output [2]: [d_date_sk#1, d_year#2]
Input [3]: [d_date_sk#1, d_year#2, d_moy#3]

(48) Exchange
Input [2]: [d_date_sk#1, d_year#2]
Arguments: hashpartitioning(d_date_sk#1, 100), ENSURE_REQUIREMENTS, [plan_id=6]

(49) Sort
Input [2]: [d_date_sk#1, d_year#2]
Arguments: [d_date_sk#1 ASC NULLS FIRST], false, 0

(50) Scan parquet
Output [3]: [ss_sold_date_sk#4, ss_item_sk#5, ss_ext_sales_price#6]
Batched: true
Location: InMemoryFileIndex [file:/<warehouse_dir>]
PushedFilters: [IsNotNull(ss_sold_date_sk), IsNotNull(ss_item_sk)]
ReadSchema: struct<ss_sold_date_sk:int,ss_item_sk:int,ss_ext_sales_price:decimal(7,2)>

(51) Filter
Input [3]: [ss_sold_date_sk#4, ss_item_sk#5, ss_ext_sales_price#6]
Condition : (isnotnull(ss_sold_date_sk#4) AND isnotnull(ss_item_sk#5))

(52) Exchange
Input [3]: [ss_sold_date_sk#4, ss_item_sk#5, ss_ext_sales_price#6]
Arguments: hashpartitioning(ss_sold_date_sk#4, 100), ENSURE_REQUIREMENTS, [plan_id=7]

(53) Sort
Input [3]: [ss_sold_date_sk#4, ss_item_sk#5, ss_ext_sales_price#6]
Arguments: [ss_sold_date_sk#4 ASC NULLS FIRST], false, 0

(54) SortMergeJoin
Left keys [1]: [d_date_sk#1]
Right keys [1]: [ss_sold_date_sk#4]
Join type: Inner
Join condition: None

(55) Project
Output [3]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6]
Input [5]: [d_date_sk#1, d_year#2, ss_sold_date_sk#4, ss_item_sk#5, ss_ext_sales_price#6]

(56) Exchange
Input [3]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6]
Arguments: hashpartitioning(ss_item_sk#5, 100), ENSURE_REQUIREMENTS, [plan_id=8]

(57) Sort
Input [3]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6]
Arguments: [ss_item_sk#5 ASC NULLS FIRST], false, 0

(58) Scan parquet
Output [4]: [i_item_sk#7, i_category_id#8, i_category#9, i_manager_id#10]
Batched: true
Location: InMemoryFileIndex [file:/<warehouse_dir>]
PushedFilters: [IsNotNull(i_manager_id), EqualTo(i_manager_id,1), IsNotNull(i_item_sk)]
ReadSchema: struct<i_item_sk:int,i_category_id:int,i_category:string,i_manager_id:int>

(59) Filter
Input [4]: [i_item_sk#7, i_category_id#8, i_category#9, i_manager_id#10]
Condition : ((isnotnull(i_manager_id#10) AND (i_manager_id#10 = 1)) AND isnotnull(i_item_sk#7))

(60) Project
Output [3]: [i_item_sk#7, i_category_id#8, i_category#9]
Input [4]: [i_item_sk#7, i_category_id#8, i_category#9, i_manager_id#10]

(61) Exchange
Input [3]: [i_item_sk#7, i_category_id#8, i_category#9]
Arguments: hashpartitioning(i_item_sk#7, 100), ENSURE_REQUIREMENTS, [plan_id=9]

(62) Sort
Input [3]: [i_item_sk#7, i_category_id#8, i_category#9]
Arguments: [i_item_sk#7 ASC NULLS FIRST], false, 0

(63) SortMergeJoin
Left keys [1]: [ss_item_sk#5]
Right keys [1]: [i_item_sk#7]
Join type: Inner
Join condition: None

(64) Project
Output [4]: [d_year#2, ss_ext_sales_price#6, i_category_id#8, i_category#9]
Input [6]: [d_year#2, ss_item_sk#5, ss_ext_sales_price#6, i_item_sk#7, i_category_id#8, i_category#9]

(65) HashAggregate
Input [4]: [d_year#2, ss_ext_sales_price#6, i_category_id#8, i_category#9]
Keys [3]: [d_year#2, i_category_id#8, i_category#9]
Functions [1]: [partial_sum(UnscaledValue(ss_ext_sales_price#6))]
Aggregate Attributes [1]: [sum#12]
Results [4]: [d_year#2, i_category_id#8, i_category#9, sum#16]

(66) Exchange
Input [4]: [d_year#2, i_category_id#8, i_category#9, sum#16]
Arguments: hashpartitioning(d_year#2, i_category_id#8, i_category#9, 100), ENSURE_REQUIREMENTS, [plan_id=10]

(67) HashAggregate
Input [4]: [d_year#2, i_category_id#8, i_category#9, sum#16]
Keys [3]: [d_year#2, i_category_id#8, i_category#9]
Functions [1]: [sum(UnscaledValue(ss_ext_sales_price#6))]
Aggregate Attributes [1]: [sum(UnscaledValue(ss_ext_sales_price#6))#14]
Results [4]: [d_year#2, i_category_id#8, i_category#9, MakeDecimal(sum(UnscaledValue(ss_ext_sales_price#6))#14,17,2) AS sum(ss_ext_sales_price)#15]

(68) TakeOrderedAndProject
Input [4]: [d_year#2, i_category_id#8, i_category#9, sum(ss_ext_sales_price)#15]
Arguments: X, [sum(ss_ext_sales_price)#15 DESC NULLS LAST, d_year#2 ASC NULLS FIRST, i_category_id#8 ASC NULLS FIRST, i_category#9 ASC NULLS FIRST], [d_year#2, i_category_id#8, i_category#9, sum(ss_ext_sales_price)#15]

(69) AdaptiveSparkPlan
Output [4]: [d_year#2, i_category_id#8, i_category#9, sum(ss_ext_sales_price)#15]
Arguments: isFinalPlan=true

