hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jcama...@apache.org
Subject [2/5] hive git commit: HIVE-17377: SharedWorkOptimizer might not iterate through TS operators deterministically (Jesus Camacho Rodriguez, reviewed by Ashutosh Chauhan)
Date Thu, 24 Aug 2017 21:06:55 GMT
http://git-wip-us.apache.org/repos/asf/hive/blob/5522a2db/ql/src/test/results/clientpositive/perf/query54.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/perf/query54.q.out b/ql/src/test/results/clientpositive/perf/query54.q.out
index fe0bbf9..be2a13e 100644
--- a/ql/src/test/results/clientpositive/perf/query54.q.out
+++ b/ql/src/test/results/clientpositive/perf/query54.q.out
@@ -1,7 +1,7 @@
-Warning: Shuffle Join MERGEJOIN[183][tables = [$hdt$_1, $hdt$_2]] in Stage 'Reducer 3' is a cross product
-Warning: Shuffle Join MERGEJOIN[184][tables = [$hdt$_0, $hdt$_1, $hdt$_2, $hdt$_3]] in Stage 'Reducer 12' is a cross product
-Warning: Shuffle Join MERGEJOIN[185][tables = [$hdt$_0, $hdt$_1, $hdt$_2, $hdt$_3, $hdt$_4]] in Stage 'Reducer 13' is a cross product
-Warning: Shuffle Join MERGEJOIN[186][tables = [$hdt$_1, $hdt$_2, $hdt$_0]] in Stage 'Reducer 4' is a cross product
+Warning: Shuffle Join MERGEJOIN[184][tables = [$hdt$_0, $hdt$_1, $hdt$_2, $hdt$_3]] in Stage 'Reducer 4' is a cross product
+Warning: Shuffle Join MERGEJOIN[185][tables = [$hdt$_0, $hdt$_1, $hdt$_2, $hdt$_3, $hdt$_4]] in Stage 'Reducer 5' is a cross product
+Warning: Shuffle Join MERGEJOIN[183][tables = [$hdt$_1, $hdt$_2]] in Stage 'Reducer 30' is a cross product
+Warning: Shuffle Join MERGEJOIN[186][tables = [$hdt$_1, $hdt$_2, $hdt$_0]] in Stage 'Reducer 6' is a cross product
 PREHOOK: query: explain
 with my_customers as (
  select distinct c_customer_sk
@@ -115,47 +115,47 @@ POSTHOOK: type: QUERY
 Plan optimized by CBO.
 
 Vertex dependency in root stage
-Map 23 <- Union 24 (CONTAINS)
-Map 29 <- Union 24 (CONTAINS)
-Reducer 10 <- Map 1 (SIMPLE_EDGE)
-Reducer 11 <- Reducer 10 (CUSTOM_SIMPLE_EDGE)
-Reducer 12 <- Reducer 11 (CUSTOM_SIMPLE_EDGE), Reducer 17 (CUSTOM_SIMPLE_EDGE)
-Reducer 13 <- Reducer 12 (CUSTOM_SIMPLE_EDGE), Reducer 14 (CUSTOM_SIMPLE_EDGE)
-Reducer 14 <- Map 1 (SIMPLE_EDGE)
-Reducer 16 <- Map 15 (SIMPLE_EDGE), Map 18 (SIMPLE_EDGE)
-Reducer 17 <- Reducer 16 (SIMPLE_EDGE), Reducer 21 (SIMPLE_EDGE)
-Reducer 2 <- Map 1 (SIMPLE_EDGE)
-Reducer 20 <- Map 19 (SIMPLE_EDGE), Map 22 (SIMPLE_EDGE)
-Reducer 21 <- Reducer 20 (SIMPLE_EDGE), Reducer 28 (SIMPLE_EDGE)
-Reducer 25 <- Map 30 (SIMPLE_EDGE), Union 24 (SIMPLE_EDGE)
-Reducer 26 <- Map 31 (SIMPLE_EDGE), Reducer 25 (SIMPLE_EDGE)
-Reducer 27 <- Map 32 (SIMPLE_EDGE), Reducer 26 (SIMPLE_EDGE)
-Reducer 28 <- Reducer 27 (SIMPLE_EDGE)
-Reducer 3 <- Reducer 2 (CUSTOM_SIMPLE_EDGE), Reducer 9 (CUSTOM_SIMPLE_EDGE)
-Reducer 4 <- Reducer 13 (CUSTOM_SIMPLE_EDGE), Reducer 3 (CUSTOM_SIMPLE_EDGE)
-Reducer 5 <- Reducer 4 (SIMPLE_EDGE)
-Reducer 6 <- Reducer 5 (SIMPLE_EDGE)
+Map 15 <- Union 16 (CONTAINS)
+Map 21 <- Union 16 (CONTAINS)
+Reducer 12 <- Map 11 (SIMPLE_EDGE), Map 14 (SIMPLE_EDGE)
+Reducer 13 <- Reducer 12 (SIMPLE_EDGE), Reducer 20 (SIMPLE_EDGE)
+Reducer 17 <- Map 22 (SIMPLE_EDGE), Union 16 (SIMPLE_EDGE)
+Reducer 18 <- Map 23 (SIMPLE_EDGE), Reducer 17 (SIMPLE_EDGE)
+Reducer 19 <- Map 24 (SIMPLE_EDGE), Reducer 18 (SIMPLE_EDGE)
+Reducer 2 <- Map 1 (SIMPLE_EDGE), Map 10 (SIMPLE_EDGE)
+Reducer 20 <- Reducer 19 (SIMPLE_EDGE)
+Reducer 26 <- Map 25 (SIMPLE_EDGE)
+Reducer 27 <- Reducer 26 (CUSTOM_SIMPLE_EDGE)
+Reducer 28 <- Map 25 (SIMPLE_EDGE)
+Reducer 29 <- Map 25 (SIMPLE_EDGE)
+Reducer 3 <- Reducer 13 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
+Reducer 30 <- Reducer 29 (CUSTOM_SIMPLE_EDGE), Reducer 32 (CUSTOM_SIMPLE_EDGE)
+Reducer 31 <- Map 25 (SIMPLE_EDGE)
+Reducer 32 <- Reducer 31 (CUSTOM_SIMPLE_EDGE)
+Reducer 4 <- Reducer 27 (CUSTOM_SIMPLE_EDGE), Reducer 3 (CUSTOM_SIMPLE_EDGE)
+Reducer 5 <- Reducer 28 (CUSTOM_SIMPLE_EDGE), Reducer 4 (CUSTOM_SIMPLE_EDGE)
+Reducer 6 <- Reducer 30 (CUSTOM_SIMPLE_EDGE), Reducer 5 (CUSTOM_SIMPLE_EDGE)
 Reducer 7 <- Reducer 6 (SIMPLE_EDGE)
-Reducer 8 <- Map 1 (SIMPLE_EDGE)
-Reducer 9 <- Reducer 8 (CUSTOM_SIMPLE_EDGE)
+Reducer 8 <- Reducer 7 (SIMPLE_EDGE)
+Reducer 9 <- Reducer 8 (SIMPLE_EDGE)
 
 Stage-0
   Fetch Operator
     limit:100
     Stage-1
-      Reducer 7
+      Reducer 9
       File Output Operator [FS_130]
         Limit [LIM_129] (rows=100 width=158)
           Number of rows:100
           Select Operator [SEL_128] (rows=1614130953450400 width=158)
             Output:["_col0","_col1","_col2"]
-          <-Reducer 6 [SIMPLE_EDGE]
+          <-Reducer 8 [SIMPLE_EDGE]
             SHUFFLE [RS_127]
               Select Operator [SEL_126] (rows=1614130953450400 width=158)
                 Output:["_col0","_col1","_col2"]
                 Group By Operator [GBY_125] (rows=1614130953450400 width=158)
                   Output:["_col0","_col1"],aggregations:["count(VALUE._col0)"],keys:KEY._col0
-                <-Reducer 5 [SIMPLE_EDGE]
+                <-Reducer 7 [SIMPLE_EDGE]
                   SHUFFLE [RS_124]
                     PartitionCols:_col0
                     Group By Operator [GBY_123] (rows=3228261906900801 width=158)
@@ -164,7 +164,7 @@ Stage-0
                         Output:["_col0"]
                         Group By Operator [GBY_120] (rows=3228261906900801 width=158)
                           Output:["_col0","_col1"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0
-                        <-Reducer 4 [SIMPLE_EDGE]
+                        <-Reducer 6 [SIMPLE_EDGE]
                           SHUFFLE [RS_119]
                             PartitionCols:_col0
                             Group By Operator [GBY_118] (rows=6456523813801603 width=158)
@@ -177,79 +177,102 @@ Stage-0
                                     Output:["_col0","_col4","_col11","_col13","_col15"]
                                     Merge Join Operator [MERGEJOIN_186] (rows=58108714324214428 width=158)
                                       Conds:(Inner),Output:["_col0","_col2","_col6","_col13","_col15"]
-                                    <-Reducer 13 [CUSTOM_SIMPLE_EDGE]
+                                    <-Reducer 30 [CUSTOM_SIMPLE_EDGE]
+                                      PARTITION_ONLY_SHUFFLE [RS_112]
+                                        Merge Join Operator [MERGEJOIN_183] (rows=9131 width=1128)
+                                          Conds:(Right Outer),Output:["_col0"]
+                                        <-Reducer 29 [CUSTOM_SIMPLE_EDGE]
+                                          PARTITION_ONLY_SHUFFLE [RS_109]
+                                            Group By Operator [GBY_6] (rows=9131 width=1119)
+                                              Output:["_col0"],keys:KEY._col0
+                                            <-Map 25 [SIMPLE_EDGE]
+                                              SHUFFLE [RS_5]
+                                                PartitionCols:_col0
+                                                Group By Operator [GBY_4] (rows=18262 width=1119)
+                                                  Output:["_col0"],keys:_col0
+                                                  Select Operator [SEL_2] (rows=18262 width=1119)
+                                                    Output:["_col0"]
+                                                    Filter Operator [FIL_174] (rows=18262 width=1119)
+                                                      predicate:((d_year = 1999) and (d_moy = 3))
+                                                      TableScan [TS_73] (rows=73049 width=1119)
+                                                        default@date_dim,date_dim,Tbl:COMPLETE,Col:NONE,Output:["d_month_seq","d_year","d_moy"]
+                                        <-Reducer 32 [CUSTOM_SIMPLE_EDGE]
+                                          PARTITION_ONLY_SHUFFLE [RS_110]
+                                            Select Operator [SEL_22] (rows=1 width=8)
+                                              Filter Operator [FIL_21] (rows=1 width=8)
+                                                predicate:(sq_count_check(_col0) <= 1)
+                                                Group By Operator [GBY_19] (rows=1 width=8)
+                                                  Output:["_col0"],aggregations:["count(VALUE._col0)"]
+                                                <-Reducer 31 [CUSTOM_SIMPLE_EDGE]
+                                                  PARTITION_ONLY_SHUFFLE [RS_18]
+                                                    Group By Operator [GBY_17] (rows=1 width=8)
+                                                      Output:["_col0"],aggregations:["count()"]
+                                                      Select Operator [SEL_15] (rows=9131 width=1119)
+                                                        Group By Operator [GBY_14] (rows=9131 width=1119)
+                                                          Output:["_col0"],keys:KEY._col0
+                                                        <-Map 25 [SIMPLE_EDGE]
+                                                          SHUFFLE [RS_13]
+                                                            PartitionCols:_col0
+                                                            Group By Operator [GBY_12] (rows=18262 width=1119)
+                                                              Output:["_col0"],keys:_col0
+                                                              Select Operator [SEL_10] (rows=18262 width=1119)
+                                                                Output:["_col0"]
+                                                                 Please refer to the previous Filter Operator [FIL_174]
+                                    <-Reducer 5 [CUSTOM_SIMPLE_EDGE]
                                       PARTITION_ONLY_SHUFFLE [RS_113]
                                         Select Operator [SEL_108] (rows=6363893803988 width=1217)
                                           Output:["_col0","_col4","_col11","_col13"]
                                           Merge Join Operator [MERGEJOIN_185] (rows=6363893803988 width=1217)
                                             Conds:(Left Outer),Output:["_col2","_col4","_col10","_col13"]
-                                          <-Reducer 12 [CUSTOM_SIMPLE_EDGE]
+                                          <-Reducer 28 [CUSTOM_SIMPLE_EDGE]
+                                            PARTITION_ONLY_SHUFFLE [RS_106]
+                                              Group By Operator [GBY_94] (rows=9131 width=1119)
+                                                Output:["_col0"],keys:KEY._col0
+                                              <-Map 25 [SIMPLE_EDGE]
+                                                SHUFFLE [RS_93]
+                                                  PartitionCols:_col0
+                                                  Group By Operator [GBY_77] (rows=18262 width=1119)
+                                                    Output:["_col0"],keys:_col0
+                                                    Select Operator [SEL_75] (rows=18262 width=1119)
+                                                      Output:["_col0"]
+                                                       Please refer to the previous Filter Operator [FIL_174]
+                                          <-Reducer 4 [CUSTOM_SIMPLE_EDGE]
                                             PARTITION_ONLY_SHUFFLE [RS_105]
                                               Merge Join Operator [MERGEJOIN_184] (rows=696954748 width=97)
                                                 Conds:(Inner),Output:["_col2","_col4","_col10"]
-                                              <-Reducer 11 [CUSTOM_SIMPLE_EDGE]
+                                              <-Reducer 27 [CUSTOM_SIMPLE_EDGE]
                                                 PARTITION_ONLY_SHUFFLE [RS_103]
                                                   Select Operator [SEL_87] (rows=1 width=8)
                                                     Filter Operator [FIL_86] (rows=1 width=8)
                                                       predicate:(sq_count_check(_col0) <= 1)
                                                       Group By Operator [GBY_84] (rows=1 width=8)
                                                         Output:["_col0"],aggregations:["count(VALUE._col0)"]
-                                                      <-Reducer 10 [CUSTOM_SIMPLE_EDGE]
+                                                      <-Reducer 26 [CUSTOM_SIMPLE_EDGE]
                                                         PARTITION_ONLY_SHUFFLE [RS_83]
                                                           Group By Operator [GBY_82] (rows=1 width=8)
                                                             Output:["_col0"],aggregations:["count()"]
                                                             Select Operator [SEL_80] (rows=9131 width=1119)
                                                               Group By Operator [GBY_79] (rows=9131 width=1119)
                                                                 Output:["_col0"],keys:KEY._col0
-                                                              <-Map 1 [SIMPLE_EDGE]
+                                                              <-Map 25 [SIMPLE_EDGE]
                                                                 SHUFFLE [RS_78]
                                                                   PartitionCols:_col0
-                                                                  Group By Operator [GBY_77] (rows=18262 width=1119)
-                                                                    Output:["_col0"],keys:_col0
-                                                                    Select Operator [SEL_75] (rows=18262 width=1119)
-                                                                      Output:["_col0"]
-                                                                      Filter Operator [FIL_163] (rows=18262 width=1119)
-                                                                        predicate:((d_year = 1999) and (d_moy = 3))
-                                                                        TableScan [TS_0] (rows=73049 width=1119)
-                                                                          default@date_dim,date_dim,Tbl:COMPLETE,Col:NONE,Output:["d_month_seq","d_year","d_moy"]
-                                              <-Reducer 17 [CUSTOM_SIMPLE_EDGE]
+                                                                   Please refer to the previous Group By Operator [GBY_77]
+                                              <-Reducer 3 [CUSTOM_SIMPLE_EDGE]
                                                 PARTITION_ONLY_SHUFFLE [RS_102]
                                                   Merge Join Operator [MERGEJOIN_182] (rows=696954748 width=88)
                                                     Conds:RS_99._col1=RS_100._col5(Inner),Output:["_col2","_col4","_col10"]
-                                                  <-Reducer 16 [SIMPLE_EDGE]
-                                                    SHUFFLE [RS_99]
-                                                      PartitionCols:_col1
-                                                      Merge Join Operator [MERGEJOIN_176] (rows=633595212 width=88)
-                                                        Conds:RS_96._col0=RS_97._col0(Inner),Output:["_col1","_col2","_col4"]
-                                                      <-Map 15 [SIMPLE_EDGE]
-                                                        SHUFFLE [RS_96]
-                                                          PartitionCols:_col0
-                                                          Select Operator [SEL_25] (rows=575995635 width=88)
-                                                            Output:["_col0","_col1","_col2"]
-                                                            Filter Operator [FIL_165] (rows=575995635 width=88)
-                                                              predicate:(ss_customer_sk is not null and ss_sold_date_sk is not null)
-                                                              TableScan [TS_23] (rows=575995635 width=88)
-                                                                default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_date_sk","ss_customer_sk","ss_ext_sales_price"]
-                                                      <-Map 18 [SIMPLE_EDGE]
-                                                        SHUFFLE [RS_97]
-                                                          PartitionCols:_col0
-                                                          Select Operator [SEL_28] (rows=73049 width=1119)
-                                                            Output:["_col0","_col1"]
-                                                            Filter Operator [FIL_166] (rows=73049 width=1119)
-                                                              predicate:d_date_sk is not null
-                                                              TableScan [TS_26] (rows=73049 width=1119)
-                                                                default@date_dim,date_dim,Tbl:COMPLETE,Col:NONE,Output:["d_date_sk","d_month_seq"]
-                                                  <-Reducer 21 [SIMPLE_EDGE]
+                                                  <-Reducer 13 [SIMPLE_EDGE]
                                                     SHUFFLE [RS_100]
                                                       PartitionCols:_col5
                                                       Merge Join Operator [MERGEJOIN_181] (rows=316240138 width=135)
                                                         Conds:RS_69._col0=RS_70._col1(Inner),Output:["_col5"]
-                                                      <-Reducer 20 [SIMPLE_EDGE]
+                                                      <-Reducer 12 [SIMPLE_EDGE]
                                                         SHUFFLE [RS_69]
                                                           PartitionCols:_col0
                                                           Merge Join Operator [MERGEJOIN_177] (rows=44000000 width=1014)
                                                             Conds:RS_66._col1, _col2=RS_67._col0, _col1(Inner),Output:["_col0"]
-                                                          <-Map 19 [SIMPLE_EDGE]
+                                                          <-Map 11 [SIMPLE_EDGE]
                                                             SHUFFLE [RS_66]
                                                               PartitionCols:_col1, _col2
                                                               Select Operator [SEL_31] (rows=40000000 width=1014)
@@ -258,7 +281,7 @@ Stage-0
                                                                   predicate:(ca_address_sk is not null and ca_county is not null and ca_state is not null)
                                                                   TableScan [TS_29] (rows=40000000 width=1014)
                                                                     default@customer_address,customer_address,Tbl:COMPLETE,Col:NONE,Output:["ca_address_sk","ca_county","ca_state"]
-                                                          <-Map 22 [SIMPLE_EDGE]
+                                                          <-Map 14 [SIMPLE_EDGE]
                                                             SHUFFLE [RS_67]
                                                               PartitionCols:_col0, _col1
                                                               Select Operator [SEL_34] (rows=1704 width=1910)
@@ -267,21 +290,21 @@ Stage-0
                                                                   predicate:(s_county is not null and s_state is not null)
                                                                   TableScan [TS_32] (rows=1704 width=1910)
                                                                     default@store,store,Tbl:COMPLETE,Col:NONE,Output:["s_county","s_state"]
-                                                      <-Reducer 28 [SIMPLE_EDGE]
+                                                      <-Reducer 20 [SIMPLE_EDGE]
                                                         SHUFFLE [RS_70]
                                                           PartitionCols:_col1
                                                           Select Operator [SEL_65] (rows=287491029 width=135)
                                                             Output:["_col0","_col1"]
                                                             Group By Operator [GBY_64] (rows=287491029 width=135)
                                                               Output:["_col0","_col1"],keys:KEY._col0, KEY._col1
-                                                            <-Reducer 27 [SIMPLE_EDGE]
+                                                            <-Reducer 19 [SIMPLE_EDGE]
                                                               SHUFFLE [RS_63]
                                                                 PartitionCols:_col0, _col1
                                                                 Group By Operator [GBY_62] (rows=574982058 width=135)
                                                                   Output:["_col0","_col1"],keys:_col10, _col9
                                                                   Merge Join Operator [MERGEJOIN_180] (rows=574982058 width=135)
                                                                     Conds:RS_58._col1=RS_59._col0(Inner),Output:["_col9","_col10"]
-                                                                  <-Map 32 [SIMPLE_EDGE]
+                                                                  <-Map 24 [SIMPLE_EDGE]
                                                                     SHUFFLE [RS_59]
                                                                       PartitionCols:_col0
                                                                       Select Operator [SEL_51] (rows=80000000 width=860)
@@ -290,12 +313,12 @@ Stage-0
                                                                           predicate:(c_customer_sk is not null and c_current_addr_sk is not null)
                                                                           TableScan [TS_49] (rows=80000000 width=860)
                                                                             default@customer,customer,Tbl:COMPLETE,Col:NONE,Output:["c_customer_sk","c_current_addr_sk"]
-                                                                  <-Reducer 26 [SIMPLE_EDGE]
+                                                                  <-Reducer 18 [SIMPLE_EDGE]
                                                                     SHUFFLE [RS_58]
                                                                       PartitionCols:_col1
                                                                       Merge Join Operator [MERGEJOIN_179] (rows=522710951 width=135)
                                                                         Conds:RS_55._col2=RS_56._col0(Inner),Output:["_col1"]
-                                                                      <-Map 31 [SIMPLE_EDGE]
+                                                                      <-Map 23 [SIMPLE_EDGE]
                                                                         SHUFFLE [RS_56]
                                                                           PartitionCols:_col0
                                                                           Select Operator [SEL_48] (rows=115500 width=1436)
@@ -304,12 +327,12 @@ Stage-0
                                                                               predicate:((i_category = 'Jewelry') and (i_class = 'consignment') and i_item_sk is not null)
                                                                               TableScan [TS_46] (rows=462000 width=1436)
                                                                                 default@item,item,Tbl:COMPLETE,Col:NONE,Output:["i_item_sk","i_class","i_category"]
-                                                                      <-Reducer 25 [SIMPLE_EDGE]
+                                                                      <-Reducer 17 [SIMPLE_EDGE]
                                                                         SHUFFLE [RS_55]
                                                                           PartitionCols:_col2
                                                                           Merge Join Operator [MERGEJOIN_178] (rows=475191764 width=135)
-                                                                            Conds:Union 24._col0=RS_53._col0(Inner),Output:["_col1","_col2"]
-                                                                          <-Map 30 [SIMPLE_EDGE]
+                                                                            Conds:Union 16._col0=RS_53._col0(Inner),Output:["_col1","_col2"]
+                                                                          <-Map 22 [SIMPLE_EDGE]
                                                                             SHUFFLE [RS_53]
                                                                               PartitionCols:_col0
                                                                               Select Operator [SEL_45] (rows=18262 width=1119)
@@ -318,8 +341,8 @@ Stage-0
                                                                                   predicate:((d_moy = 3) and (d_year = 1999) and d_date_sk is not null)
                                                                                   TableScan [TS_43] (rows=73049 width=1119)
                                                                                     default@date_dim,date_dim,Tbl:COMPLETE,Col:NONE,Output:["d_date_sk","d_year","d_moy"]
-                                                                          <-Union 24 [SIMPLE_EDGE]
-                                                                            <-Map 23 [CONTAINS]
+                                                                          <-Union 16 [SIMPLE_EDGE]
+                                                                            <-Map 15 [CONTAINS]
                                                                               Reduce Output Operator [RS_52]
                                                                                 PartitionCols:_col0
                                                                                 Select Operator [SEL_37] (rows=287989836 width=135)
@@ -328,7 +351,7 @@ Stage-0
                                                                                     predicate:(cs_item_sk is not null and cs_sold_date_sk is not null and cs_bill_customer_sk is not null)
                                                                                     TableScan [TS_35] (rows=287989836 width=135)
                                                                                       Output:["cs_sold_date_sk","cs_bill_customer_sk","cs_item_sk"]
-                                                                            <-Map 29 [CONTAINS]
+                                                                            <-Map 21 [CONTAINS]
                                                                               Reduce Output Operator [RS_52]
                                                                                 PartitionCols:_col0
                                                                                 Select Operator [SEL_40] (rows=144002668 width=135)
@@ -337,50 +360,27 @@ Stage-0
                                                                                     predicate:(ws_item_sk is not null and ws_sold_date_sk is not null and ws_bill_customer_sk is not null)
                                                                                     TableScan [TS_38] (rows=144002668 width=135)
                                                                                       Output:["ws_sold_date_sk","ws_item_sk","ws_bill_customer_sk"]
-                                          <-Reducer 14 [CUSTOM_SIMPLE_EDGE]
-                                            PARTITION_ONLY_SHUFFLE [RS_106]
-                                              Group By Operator [GBY_94] (rows=9131 width=1119)
-                                                Output:["_col0"],keys:KEY._col0
-                                              <-Map 1 [SIMPLE_EDGE]
-                                                SHUFFLE [RS_93]
-                                                  PartitionCols:_col0
-                                                  Group By Operator [GBY_92] (rows=18262 width=1119)
-                                                    Output:["_col0"],keys:_col0
-                                                    Select Operator [SEL_90] (rows=18262 width=1119)
-                                                      Output:["_col0"]
-                                                       Please refer to the previous Filter Operator [FIL_163]
-                                    <-Reducer 3 [CUSTOM_SIMPLE_EDGE]
-                                      PARTITION_ONLY_SHUFFLE [RS_112]
-                                        Merge Join Operator [MERGEJOIN_183] (rows=9131 width=1128)
-                                          Conds:(Right Outer),Output:["_col0"]
-                                        <-Reducer 2 [CUSTOM_SIMPLE_EDGE]
-                                          PARTITION_ONLY_SHUFFLE [RS_109]
-                                            Group By Operator [GBY_6] (rows=9131 width=1119)
-                                              Output:["_col0"],keys:KEY._col0
-                                            <-Map 1 [SIMPLE_EDGE]
-                                              SHUFFLE [RS_5]
-                                                PartitionCols:_col0
-                                                Group By Operator [GBY_4] (rows=18262 width=1119)
-                                                  Output:["_col0"],keys:_col0
-                                                  Select Operator [SEL_2] (rows=18262 width=1119)
-                                                    Output:["_col0"]
-                                                     Please refer to the previous Filter Operator [FIL_163]
-                                        <-Reducer 9 [CUSTOM_SIMPLE_EDGE]
-                                          PARTITION_ONLY_SHUFFLE [RS_110]
-                                            Select Operator [SEL_22] (rows=1 width=8)
-                                              Filter Operator [FIL_21] (rows=1 width=8)
-                                                predicate:(sq_count_check(_col0) <= 1)
-                                                Group By Operator [GBY_19] (rows=1 width=8)
-                                                  Output:["_col0"],aggregations:["count(VALUE._col0)"]
-                                                <-Reducer 8 [CUSTOM_SIMPLE_EDGE]
-                                                  PARTITION_ONLY_SHUFFLE [RS_18]
-                                                    Group By Operator [GBY_17] (rows=1 width=8)
-                                                      Output:["_col0"],aggregations:["count()"]
-                                                      Select Operator [SEL_15] (rows=9131 width=1119)
-                                                        Group By Operator [GBY_14] (rows=9131 width=1119)
-                                                          Output:["_col0"],keys:KEY._col0
-                                                        <-Map 1 [SIMPLE_EDGE]
-                                                          SHUFFLE [RS_13]
-                                                            PartitionCols:_col0
-                                                             Please refer to the previous Group By Operator [GBY_4]
+                                                  <-Reducer 2 [SIMPLE_EDGE]
+                                                    SHUFFLE [RS_99]
+                                                      PartitionCols:_col1
+                                                      Merge Join Operator [MERGEJOIN_176] (rows=633595212 width=88)
+                                                        Conds:RS_96._col0=RS_97._col0(Inner),Output:["_col1","_col2","_col4"]
+                                                      <-Map 1 [SIMPLE_EDGE]
+                                                        SHUFFLE [RS_96]
+                                                          PartitionCols:_col0
+                                                          Select Operator [SEL_25] (rows=575995635 width=88)
+                                                            Output:["_col0","_col1","_col2"]
+                                                            Filter Operator [FIL_165] (rows=575995635 width=88)
+                                                              predicate:(ss_customer_sk is not null and ss_sold_date_sk is not null)
+                                                              TableScan [TS_23] (rows=575995635 width=88)
+                                                                default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_date_sk","ss_customer_sk","ss_ext_sales_price"]
+                                                      <-Map 10 [SIMPLE_EDGE]
+                                                        SHUFFLE [RS_97]
+                                                          PartitionCols:_col0
+                                                          Select Operator [SEL_28] (rows=73049 width=1119)
+                                                            Output:["_col0","_col1"]
+                                                            Filter Operator [FIL_166] (rows=73049 width=1119)
+                                                              predicate:d_date_sk is not null
+                                                              TableScan [TS_26] (rows=73049 width=1119)
+                                                                default@date_dim,date_dim,Tbl:COMPLETE,Col:NONE,Output:["d_date_sk","d_month_seq"]
 

http://git-wip-us.apache.org/repos/asf/hive/blob/5522a2db/ql/src/test/results/clientpositive/perf/query57.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/perf/query57.q.out b/ql/src/test/results/clientpositive/perf/query57.q.out
index 372e760..e9630de 100644
--- a/ql/src/test/results/clientpositive/perf/query57.q.out
+++ b/ql/src/test/results/clientpositive/perf/query57.q.out
@@ -99,10 +99,10 @@ Reducer 10 <- Map 21 (SIMPLE_EDGE), Reducer 9 (SIMPLE_EDGE)
 Reducer 11 <- Map 22 (SIMPLE_EDGE), Reducer 10 (SIMPLE_EDGE)
 Reducer 12 <- Reducer 11 (SIMPLE_EDGE)
 Reducer 13 <- Reducer 12 (SIMPLE_EDGE)
-Reducer 14 <- Reducer 13 (SIMPLE_EDGE)
-Reducer 15 <- Map 1 (SIMPLE_EDGE), Map 20 (SIMPLE_EDGE)
-Reducer 16 <- Map 21 (SIMPLE_EDGE), Reducer 15 (SIMPLE_EDGE)
-Reducer 17 <- Map 22 (SIMPLE_EDGE), Reducer 16 (SIMPLE_EDGE)
+Reducer 14 <- Map 1 (SIMPLE_EDGE), Map 20 (SIMPLE_EDGE)
+Reducer 15 <- Map 21 (SIMPLE_EDGE), Reducer 14 (SIMPLE_EDGE)
+Reducer 16 <- Map 22 (SIMPLE_EDGE), Reducer 15 (SIMPLE_EDGE)
+Reducer 17 <- Reducer 16 (SIMPLE_EDGE)
 Reducer 18 <- Reducer 17 (SIMPLE_EDGE)
 Reducer 19 <- Reducer 18 (SIMPLE_EDGE)
 Reducer 2 <- Map 1 (SIMPLE_EDGE), Map 20 (SIMPLE_EDGE)
@@ -110,7 +110,7 @@ Reducer 3 <- Map 21 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
 Reducer 4 <- Map 22 (SIMPLE_EDGE), Reducer 3 (SIMPLE_EDGE)
 Reducer 5 <- Reducer 4 (SIMPLE_EDGE)
 Reducer 6 <- Reducer 5 (SIMPLE_EDGE)
-Reducer 7 <- Reducer 14 (SIMPLE_EDGE), Reducer 19 (SIMPLE_EDGE), Reducer 6 (SIMPLE_EDGE)
+Reducer 7 <- Reducer 13 (SIMPLE_EDGE), Reducer 19 (SIMPLE_EDGE), Reducer 6 (SIMPLE_EDGE)
 Reducer 8 <- Reducer 7 (SIMPLE_EDGE)
 Reducer 9 <- Map 1 (SIMPLE_EDGE), Map 20 (SIMPLE_EDGE)
 
@@ -130,7 +130,78 @@ Stage-0
                 Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7","_col8"]
                 Merge Join Operator [MERGEJOIN_189] (rows=421645952 width=135)
                   Conds:RS_103._col0, _col2, _col1, (_col6 + 1)=RS_104._col0, _col2, _col1, _col7(Inner),RS_104._col0, _col2, _col1, _col7=RS_105._col0, _col2, _col1, (_col6 - 1)(Inner),Output:["_col5","_col7","_col8","_col10","_col11","_col12","_col13","_col20"]
-                <-Reducer 14 [SIMPLE_EDGE]
+                <-Reducer 13 [SIMPLE_EDGE]
+                  SHUFFLE [RS_103]
+                    PartitionCols:_col0, _col2, _col1, (_col6 + 1)
+                    Select Operator [SEL_29] (rows=191657247 width=135)
+                      Output:["_col0","_col1","_col2","_col5","_col6"]
+                      Filter Operator [FIL_164] (rows=191657247 width=135)
+                        predicate:rank_window_0 is not null
+                        PTF Operator [PTF_28] (rows=191657247 width=135)
+                          Function definitions:[{},{"name:":"windowingtablefunction","order by:":"_col3 ASC NULLS FIRST, _col4 ASC NULLS FIRST","partition by:":"_col0, _col1, _col2"}]
+                          Select Operator [SEL_27] (rows=191657247 width=135)
+                            Output:["_col0","_col1","_col2","_col3","_col4","_col5"]
+                          <-Reducer 12 [SIMPLE_EDGE]
+                            SHUFFLE [RS_26]
+                              PartitionCols:_col0, _col1, _col2
+                              Select Operator [SEL_25] (rows=191657247 width=135)
+                                Output:["_col0","_col1","_col2","_col3","_col4","_col5"]
+                                Group By Operator [GBY_24] (rows=191657247 width=135)
+                                  Output:["_col0","_col1","_col2","_col3","_col4","_col5"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0, KEY._col1, KEY._col2, KEY._col3, KEY._col4
+                                <-Reducer 11 [SIMPLE_EDGE]
+                                  SHUFFLE [RS_23]
+                                    PartitionCols:_col0, _col1, _col2, _col3, _col4
+                                    Group By Operator [GBY_22] (rows=383314495 width=135)
+                                      Output:["_col0","_col1","_col2","_col3","_col4","_col5"],aggregations:["sum(_col3)"],keys:_col5, _col6, _col8, _col10, _col11
+                                      Merge Join Operator [MERGEJOIN_182] (rows=383314495 width=135)
+                                        Conds:RS_18._col2=RS_19._col0(Inner),Output:["_col3","_col5","_col6","_col8","_col10","_col11"]
+                                      <-Map 22 [SIMPLE_EDGE]
+                                        SHUFFLE [RS_19]
+                                          PartitionCols:_col0
+                                          Select Operator [SEL_81] (rows=462000 width=1436)
+                                            Output:["_col0","_col1","_col2"]
+                                            Filter Operator [FIL_179] (rows=462000 width=1436)
+                                              predicate:(i_item_sk is not null and i_category is not null and i_brand is not null)
+                                              TableScan [TS_79] (rows=462000 width=1436)
+                                                default@item,item,Tbl:COMPLETE,Col:NONE,Output:["i_item_sk","i_brand","i_category"]
+                                      <-Reducer 10 [SIMPLE_EDGE]
+                                        SHUFFLE [RS_18]
+                                          PartitionCols:_col2
+                                          Merge Join Operator [MERGEJOIN_181] (rows=348467716 width=135)
+                                            Conds:RS_15._col1=RS_16._col0(Inner),Output:["_col2","_col3","_col5","_col6","_col8"]
+                                          <-Map 21 [SIMPLE_EDGE]
+                                            SHUFFLE [RS_16]
+                                              PartitionCols:_col0
+                                              Select Operator [SEL_78] (rows=60 width=2045)
+                                                Output:["_col0","_col1"]
+                                                Filter Operator [FIL_178] (rows=60 width=2045)
+                                                  predicate:(cc_call_center_sk is not null and cc_name is not null)
+                                                  TableScan [TS_76] (rows=60 width=2045)
+                                                    default@call_center,call_center,Tbl:COMPLETE,Col:NONE,Output:["cc_call_center_sk","cc_name"]
+                                          <-Reducer 9 [SIMPLE_EDGE]
+                                            SHUFFLE [RS_15]
+                                              PartitionCols:_col1
+                                              Merge Join Operator [MERGEJOIN_180] (rows=316788826 width=135)
+                                                Conds:RS_12._col0=RS_13._col0(Inner),Output:["_col1","_col2","_col3","_col5","_col6"]
+                                              <-Map 1 [SIMPLE_EDGE]
+                                                SHUFFLE [RS_12]
+                                                  PartitionCols:_col0
+                                                  Select Operator [SEL_72] (rows=287989836 width=135)
+                                                    Output:["_col0","_col1","_col2","_col3"]
+                                                    Filter Operator [FIL_176] (rows=287989836 width=135)
+                                                      predicate:(cs_item_sk is not null and cs_sold_date_sk is not null and cs_call_center_sk is not null)
+                                                      TableScan [TS_70] (rows=287989836 width=135)
+                                                        default@catalog_sales,catalog_sales,Tbl:COMPLETE,Col:NONE,Output:["cs_sold_date_sk","cs_call_center_sk","cs_item_sk","cs_sales_price"]
+                                              <-Map 20 [SIMPLE_EDGE]
+                                                SHUFFLE [RS_13]
+                                                  PartitionCols:_col0
+                                                  Select Operator [SEL_75] (rows=73048 width=1119)
+                                                    Output:["_col0","_col1","_col2"]
+                                                    Filter Operator [FIL_177] (rows=73048 width=1119)
+                                                      predicate:(((d_year = 2000) or ((d_year = 1999) and (d_moy = 12)) or ((d_year = 2001) and (d_moy = 1))) and d_date_sk is not null)
+                                                      TableScan [TS_73] (rows=73049 width=1119)
+                                                        default@date_dim,date_dim,Tbl:COMPLETE,Col:NONE,Output:["d_date_sk","d_year","d_moy"]
+                <-Reducer 19 [SIMPLE_EDGE]
                   SHUFFLE [RS_104]
                     PartitionCols:_col0, _col2, _col1, _col7
                     Select Operator [SEL_67] (rows=15971437 width=135)
@@ -145,7 +216,7 @@ Stage-0
                               Function definitions:[{},{"name:":"windowingtablefunction","order by:":"_col4 ASC NULLS FIRST, _col5 ASC NULLS FIRST","partition by:":"_col1, _col2, _col3"}]
                               Select Operator [SEL_64] (rows=191657247 width=135)
                                 Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6"]
-                              <-Reducer 13 [SIMPLE_EDGE]
+                              <-Reducer 18 [SIMPLE_EDGE]
                                 SHUFFLE [RS_63]
                                   PartitionCols:_col0, _col1, _col2
                                   Select Operator [SEL_62] (rows=191657247 width=135)
@@ -154,14 +225,14 @@ Stage-0
                                       Function definitions:[{},{"name:":"windowingtablefunction","order by:":"_col0 ASC NULLS FIRST, _col1 ASC NULLS FIRST, _col2 ASC NULLS FIRST, _col3 ASC NULLS FIRST","partition by:":"_col0, _col1, _col2, _col3"}]
                                       Select Operator [SEL_60] (rows=191657247 width=135)
                                         Output:["_col0","_col1","_col2","_col3","_col4","_col5"]
-                                      <-Reducer 12 [SIMPLE_EDGE]
+                                      <-Reducer 17 [SIMPLE_EDGE]
                                         SHUFFLE [RS_59]
                                           PartitionCols:_col0, _col1, _col2, _col3
                                           Select Operator [SEL_58] (rows=191657247 width=135)
                                             Output:["_col0","_col1","_col2","_col3","_col4","_col5"]
                                             Group By Operator [GBY_57] (rows=191657247 width=135)
                                               Output:["_col0","_col1","_col2","_col3","_col4","_col5"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0, KEY._col1, KEY._col2, KEY._col3, KEY._col4
-                                            <-Reducer 11 [SIMPLE_EDGE]
+                                            <-Reducer 16 [SIMPLE_EDGE]
                                               SHUFFLE [RS_56]
                                                 PartitionCols:_col0, _col1, _col2, _col3, _col4
                                                 Group By Operator [GBY_55] (rows=383314495 width=135)
@@ -171,13 +242,8 @@ Stage-0
                                                   <-Map 22 [SIMPLE_EDGE]
                                                     SHUFFLE [RS_52]
                                                       PartitionCols:_col0
-                                                      Select Operator [SEL_11] (rows=462000 width=1436)
-                                                        Output:["_col0","_col1","_col2"]
-                                                        Filter Operator [FIL_168] (rows=462000 width=1436)
-                                                          predicate:(i_item_sk is not null and i_category is not null and i_brand is not null)
-                                                          TableScan [TS_9] (rows=462000 width=1436)
-                                                            default@item,item,Tbl:COMPLETE,Col:NONE,Output:["i_item_sk","i_brand","i_category"]
-                                                  <-Reducer 10 [SIMPLE_EDGE]
+                                                       Please refer to the previous Select Operator [SEL_81]
+                                                  <-Reducer 15 [SIMPLE_EDGE]
                                                     SHUFFLE [RS_51]
                                                       PartitionCols:_col2
                                                       Merge Join Operator [MERGEJOIN_184] (rows=348467716 width=135)
@@ -185,13 +251,8 @@ Stage-0
                                                       <-Map 21 [SIMPLE_EDGE]
                                                         SHUFFLE [RS_49]
                                                           PartitionCols:_col0
-                                                          Select Operator [SEL_8] (rows=60 width=2045)
-                                                            Output:["_col0","_col1"]
-                                                            Filter Operator [FIL_167] (rows=60 width=2045)
-                                                              predicate:(cc_call_center_sk is not null and cc_name is not null)
-                                                              TableScan [TS_6] (rows=60 width=2045)
-                                                                default@call_center,call_center,Tbl:COMPLETE,Col:NONE,Output:["cc_call_center_sk","cc_name"]
-                                                      <-Reducer 9 [SIMPLE_EDGE]
+                                                           Please refer to the previous Select Operator [SEL_78]
+                                                      <-Reducer 14 [SIMPLE_EDGE]
                                                         SHUFFLE [RS_48]
                                                           PartitionCols:_col1
                                                           Merge Join Operator [MERGEJOIN_183] (rows=316788826 width=135)
@@ -199,22 +260,12 @@ Stage-0
                                                           <-Map 1 [SIMPLE_EDGE]
                                                             SHUFFLE [RS_45]
                                                               PartitionCols:_col0
-                                                              Select Operator [SEL_2] (rows=287989836 width=135)
-                                                                Output:["_col0","_col1","_col2","_col3"]
-                                                                Filter Operator [FIL_165] (rows=287989836 width=135)
-                                                                  predicate:(cs_item_sk is not null and cs_sold_date_sk is not null and cs_call_center_sk is not null)
-                                                                  TableScan [TS_0] (rows=287989836 width=135)
-                                                                    default@catalog_sales,catalog_sales,Tbl:COMPLETE,Col:NONE,Output:["cs_sold_date_sk","cs_call_center_sk","cs_item_sk","cs_sales_price"]
+                                                               Please refer to the previous Select Operator [SEL_72]
                                                           <-Map 20 [SIMPLE_EDGE]
                                                             SHUFFLE [RS_46]
                                                               PartitionCols:_col0
-                                                              Select Operator [SEL_5] (rows=73048 width=1119)
-                                                                Output:["_col0","_col1","_col2"]
-                                                                Filter Operator [FIL_166] (rows=73048 width=1119)
-                                                                  predicate:(((d_year = 2000) or ((d_year = 1999) and (d_moy = 12)) or ((d_year = 2001) and (d_moy = 1))) and d_date_sk is not null)
-                                                                  TableScan [TS_3] (rows=73049 width=1119)
-                                                                    default@date_dim,date_dim,Tbl:COMPLETE,Col:NONE,Output:["d_date_sk","d_year","d_moy"]
-                <-Reducer 19 [SIMPLE_EDGE]
+                                                               Please refer to the previous Select Operator [SEL_75]
+                <-Reducer 6 [SIMPLE_EDGE]
                   SHUFFLE [RS_105]
                     PartitionCols:_col0, _col2, _col1, (_col6 - 1)
                     Select Operator [SEL_99] (rows=191657247 width=135)
@@ -225,14 +276,14 @@ Stage-0
                           Function definitions:[{},{"name:":"windowingtablefunction","order by:":"_col3 ASC NULLS FIRST, _col4 ASC NULLS FIRST","partition by:":"_col0, _col1, _col2"}]
                           Select Operator [SEL_97] (rows=191657247 width=135)
                             Output:["_col0","_col1","_col2","_col3","_col4","_col5"]
-                          <-Reducer 18 [SIMPLE_EDGE]
+                          <-Reducer 5 [SIMPLE_EDGE]
                             SHUFFLE [RS_96]
                               PartitionCols:_col0, _col1, _col2
                               Select Operator [SEL_95] (rows=191657247 width=135)
                                 Output:["_col0","_col1","_col2","_col3","_col4","_col5"]
                                 Group By Operator [GBY_94] (rows=191657247 width=135)
                                   Output:["_col0","_col1","_col2","_col3","_col4","_col5"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0, KEY._col1, KEY._col2, KEY._col3, KEY._col4
-                                <-Reducer 17 [SIMPLE_EDGE]
+                                <-Reducer 4 [SIMPLE_EDGE]
                                   SHUFFLE [RS_93]
                                     PartitionCols:_col0, _col1, _col2, _col3, _col4
                                     Group By Operator [GBY_92] (rows=383314495 width=135)
@@ -242,8 +293,8 @@ Stage-0
                                       <-Map 22 [SIMPLE_EDGE]
                                         SHUFFLE [RS_89]
                                           PartitionCols:_col0
-                                           Please refer to the previous Select Operator [SEL_11]
-                                      <-Reducer 16 [SIMPLE_EDGE]
+                                           Please refer to the previous Select Operator [SEL_81]
+                                      <-Reducer 3 [SIMPLE_EDGE]
                                         SHUFFLE [RS_88]
                                           PartitionCols:_col2
                                           Merge Join Operator [MERGEJOIN_187] (rows=348467716 width=135)
@@ -251,8 +302,8 @@ Stage-0
                                           <-Map 21 [SIMPLE_EDGE]
                                             SHUFFLE [RS_86]
                                               PartitionCols:_col0
-                                               Please refer to the previous Select Operator [SEL_8]
-                                          <-Reducer 15 [SIMPLE_EDGE]
+                                               Please refer to the previous Select Operator [SEL_78]
+                                          <-Reducer 2 [SIMPLE_EDGE]
                                             SHUFFLE [RS_85]
                                               PartitionCols:_col1
                                               Merge Join Operator [MERGEJOIN_186] (rows=316788826 width=135)
@@ -260,60 +311,9 @@ Stage-0
                                               <-Map 1 [SIMPLE_EDGE]
                                                 SHUFFLE [RS_82]
                                                   PartitionCols:_col0
-                                                   Please refer to the previous Select Operator [SEL_2]
+                                                   Please refer to the previous Select Operator [SEL_72]
                                               <-Map 20 [SIMPLE_EDGE]
                                                 SHUFFLE [RS_83]
                                                   PartitionCols:_col0
-                                                   Please refer to the previous Select Operator [SEL_5]
-                <-Reducer 6 [SIMPLE_EDGE]
-                  SHUFFLE [RS_103]
-                    PartitionCols:_col0, _col2, _col1, (_col6 + 1)
-                    Select Operator [SEL_29] (rows=191657247 width=135)
-                      Output:["_col0","_col1","_col2","_col5","_col6"]
-                      Filter Operator [FIL_164] (rows=191657247 width=135)
-                        predicate:rank_window_0 is not null
-                        PTF Operator [PTF_28] (rows=191657247 width=135)
-                          Function definitions:[{},{"name:":"windowingtablefunction","order by:":"_col3 ASC NULLS FIRST, _col4 ASC NULLS FIRST","partition by:":"_col0, _col1, _col2"}]
-                          Select Operator [SEL_27] (rows=191657247 width=135)
-                            Output:["_col0","_col1","_col2","_col3","_col4","_col5"]
-                          <-Reducer 5 [SIMPLE_EDGE]
-                            SHUFFLE [RS_26]
-                              PartitionCols:_col0, _col1, _col2
-                              Select Operator [SEL_25] (rows=191657247 width=135)
-                                Output:["_col0","_col1","_col2","_col3","_col4","_col5"]
-                                Group By Operator [GBY_24] (rows=191657247 width=135)
-                                  Output:["_col0","_col1","_col2","_col3","_col4","_col5"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0, KEY._col1, KEY._col2, KEY._col3, KEY._col4
-                                <-Reducer 4 [SIMPLE_EDGE]
-                                  SHUFFLE [RS_23]
-                                    PartitionCols:_col0, _col1, _col2, _col3, _col4
-                                    Group By Operator [GBY_22] (rows=383314495 width=135)
-                                      Output:["_col0","_col1","_col2","_col3","_col4","_col5"],aggregations:["sum(_col3)"],keys:_col5, _col6, _col8, _col10, _col11
-                                      Merge Join Operator [MERGEJOIN_182] (rows=383314495 width=135)
-                                        Conds:RS_18._col2=RS_19._col0(Inner),Output:["_col3","_col5","_col6","_col8","_col10","_col11"]
-                                      <-Map 22 [SIMPLE_EDGE]
-                                        SHUFFLE [RS_19]
-                                          PartitionCols:_col0
-                                           Please refer to the previous Select Operator [SEL_11]
-                                      <-Reducer 3 [SIMPLE_EDGE]
-                                        SHUFFLE [RS_18]
-                                          PartitionCols:_col2
-                                          Merge Join Operator [MERGEJOIN_181] (rows=348467716 width=135)
-                                            Conds:RS_15._col1=RS_16._col0(Inner),Output:["_col2","_col3","_col5","_col6","_col8"]
-                                          <-Map 21 [SIMPLE_EDGE]
-                                            SHUFFLE [RS_16]
-                                              PartitionCols:_col0
-                                               Please refer to the previous Select Operator [SEL_8]
-                                          <-Reducer 2 [SIMPLE_EDGE]
-                                            SHUFFLE [RS_15]
-                                              PartitionCols:_col1
-                                              Merge Join Operator [MERGEJOIN_180] (rows=316788826 width=135)
-                                                Conds:RS_12._col0=RS_13._col0(Inner),Output:["_col1","_col2","_col3","_col5","_col6"]
-                                              <-Map 1 [SIMPLE_EDGE]
-                                                SHUFFLE [RS_12]
-                                                  PartitionCols:_col0
-                                                   Please refer to the previous Select Operator [SEL_2]
-                                              <-Map 20 [SIMPLE_EDGE]
-                                                SHUFFLE [RS_13]
-                                                  PartitionCols:_col0
-                                                   Please refer to the previous Select Operator [SEL_5]
+                                                   Please refer to the previous Select Operator [SEL_75]
 

http://git-wip-us.apache.org/repos/asf/hive/blob/5522a2db/ql/src/test/results/clientpositive/perf/query58.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/perf/query58.q.out b/ql/src/test/results/clientpositive/perf/query58.q.out
index 7be1ff5..ca1a5b3 100644
--- a/ql/src/test/results/clientpositive/perf/query58.q.out
+++ b/ql/src/test/results/clientpositive/perf/query58.q.out
@@ -222,7 +222,7 @@ Stage-0
                                                 Output:["_col0","_col1"]
                                                 Filter Operator [FIL_257] (rows=73049 width=1119)
                                                   predicate:(d_week_seq is not null and d_date is not null)
-                                                  TableScan [TS_18] (rows=73049 width=1119)
+                                                  TableScan [TS_21] (rows=73049 width=1119)
                                                     default@date_dim,date_dim,Tbl:COMPLETE,Col:NONE,Output:["d_date","d_week_seq"]
                                           <-Reducer 24 [SIMPLE_EDGE]
                                             SHUFFLE [RS_77]
@@ -235,7 +235,7 @@ Stage-0
                                                     Output:["_col0"]
                                                     Filter Operator [FIL_256] (rows=36524 width=1119)
                                                       predicate:((d_date = '1998-02-19') and d_week_seq is not null)
-                                                       Please refer to the previous TableScan [TS_18]
+                                                       Please refer to the previous TableScan [TS_21]
                                               <-Reducer 23 [CUSTOM_SIMPLE_EDGE]
                                                 PARTITION_ONLY_SHUFFLE [RS_74]
                                                   Select Operator [SEL_67] (rows=1 width=8)
@@ -333,7 +333,7 @@ Stage-0
                                                 Output:["_col0","_col1"]
                                                 Filter Operator [FIL_263] (rows=73049 width=1119)
                                                   predicate:(d_week_seq is not null and d_date is not null)
-                                                   Please refer to the previous TableScan [TS_18]
+                                                   Please refer to the previous TableScan [TS_21]
                                           <-Reducer 28 [SIMPLE_EDGE]
                                             SHUFFLE [RS_127]
                                               PartitionCols:_col1
@@ -345,7 +345,7 @@ Stage-0
                                                     Output:["_col0"]
                                                     Filter Operator [FIL_262] (rows=36524 width=1119)
                                                       predicate:((d_date = '1998-02-19') and d_week_seq is not null)
-                                                       Please refer to the previous TableScan [TS_18]
+                                                       Please refer to the previous TableScan [TS_21]
                                               <-Reducer 27 [CUSTOM_SIMPLE_EDGE]
                                                 PARTITION_ONLY_SHUFFLE [RS_124]
                                                   Select Operator [SEL_117] (rows=1 width=8)
@@ -396,7 +396,7 @@ Stage-0
                                                 Output:["_col0","_col1"]
                                                 Filter Operator [FIL_251] (rows=73049 width=1119)
                                                   predicate:(d_week_seq is not null and d_date is not null)
-                                                   Please refer to the previous TableScan [TS_18]
+                                                   Please refer to the previous TableScan [TS_21]
                                           <-Reducer 20 [SIMPLE_EDGE]
                                             SHUFFLE [RS_27]
                                               PartitionCols:_col1
@@ -408,7 +408,7 @@ Stage-0
                                                     Output:["_col0"]
                                                     Filter Operator [FIL_250] (rows=36524 width=1119)
                                                       predicate:((d_date = '1998-02-19') and d_week_seq is not null)
-                                                       Please refer to the previous TableScan [TS_18]
+                                                       Please refer to the previous TableScan [TS_21]
                                               <-Reducer 19 [CUSTOM_SIMPLE_EDGE]
                                                 PARTITION_ONLY_SHUFFLE [RS_24]
                                                   Select Operator [SEL_17] (rows=1 width=8)


Mime
View raw message