You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by sp...@apache.org on 2016/05/26 15:40:30 UTC

[08/66] [abbrv] hive git commit: HIVE-13068: Disable Hive ConstantPropagate optimizer when CBO has optimized the plan II (Jesus Camacho Rodriguez, reviewed by Ashutosh Chauhan)

http://git-wip-us.apache.org/repos/asf/hive/blob/10423f51/ql/src/test/results/clientpositive/perf/query88.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/perf/query88.q.out b/ql/src/test/results/clientpositive/perf/query88.q.out
index e3f69d3..9981af5 100644
--- a/ql/src/test/results/clientpositive/perf/query88.q.out
+++ b/ql/src/test/results/clientpositive/perf/query88.q.out
@@ -1,4 +1,4 @@
-Warning: Shuffle Join MERGEJOIN[354][tables = [$hdt$_0, $hdt$_1, $hdt$_2, $hdt$_3, $hdt$_4, $hdt$_5, $hdt$_6, $hdt$_7]] in Stage 'Reducer 6' is a cross product
+Warning: Shuffle Join MERGEJOIN[347][tables = [$hdt$_0, $hdt$_1, $hdt$_2, $hdt$_3, $hdt$_4, $hdt$_5, $hdt$_6, $hdt$_7]] in Stage 'Reducer 6' is a cross product
 PREHOOK: query: explain
 select  *
 from
@@ -225,55 +225,55 @@ Stage-0
     limit:-1
     Stage-1
       Reducer 6
-      File Output Operator [FS_225]
-        Select Operator [SEL_224] (rows=7 width=8)
+      File Output Operator [FS_218]
+        Select Operator [SEL_217] (rows=7 width=8)
           Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7"]
-          Merge Join Operator [MERGEJOIN_354] (rows=7 width=8)
+          Merge Join Operator [MERGEJOIN_347] (rows=7 width=8)
             Conds:(Inner),(Inner),(Inner),(Inner),(Inner),(Inner),(Inner),Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7"]
           <-Reducer 14 [SIMPLE_EDGE]
-            SHUFFLE [RS_216]
+            SHUFFLE [RS_209]
               Group By Operator [GBY_50] (rows=1 width=8)
                 Output:["_col0"],aggregations:["count(VALUE._col0)"]
               <-Reducer 13 [SIMPLE_EDGE]
                 SHUFFLE [RS_49]
                   Group By Operator [GBY_48] (rows=1 width=8)
                     Output:["_col0"],aggregations:["count()"]
-                    Merge Join Operator [MERGEJOIN_335] (rows=766650239 width=88)
+                    Merge Join Operator [MERGEJOIN_328] (rows=766650239 width=88)
                       Conds:RS_44._col2=RS_45._col0(Inner)
                     <-Map 17 [SIMPLE_EDGE]
                       SHUFFLE [RS_45]
                         PartitionCols:_col0
                         Select Operator [SEL_37] (rows=852 width=1910)
                           Output:["_col0"]
-                          Filter Operator [FIL_305] (rows=852 width=1910)
+                          Filter Operator [FIL_298] (rows=852 width=1910)
                             predicate:((s_store_name = 'ese') and s_store_sk is not null)
                             TableScan [TS_35] (rows=1704 width=1910)
                               default@store,store,Tbl:COMPLETE,Col:NONE,Output:["s_store_sk","s_store_name"]
                     <-Reducer 12 [SIMPLE_EDGE]
                       SHUFFLE [RS_44]
                         PartitionCols:_col2
-                        Merge Join Operator [MERGEJOIN_334] (rows=696954748 width=88)
+                        Merge Join Operator [MERGEJOIN_327] (rows=696954748 width=88)
                           Conds:RS_41._col1=RS_42._col0(Inner),Output:["_col2"]
                         <-Map 16 [SIMPLE_EDGE]
                           SHUFFLE [RS_42]
                             PartitionCols:_col0
                             Select Operator [SEL_34] (rows=3600 width=107)
                               Output:["_col0"]
-                              Filter Operator [FIL_304] (rows=3600 width=107)
+                              Filter Operator [FIL_297] (rows=3600 width=107)
                                 predicate:((((hd_dep_count = 3) and (hd_vehicle_count <= 5)) or ((hd_dep_count = 0) and (hd_vehicle_count <= 2)) or ((hd_dep_count = 1) and (hd_vehicle_count <= 3))) and hd_demo_sk is not null)
                                 TableScan [TS_32] (rows=7200 width=107)
                                   default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count","hd_vehicle_count"]
                         <-Reducer 11 [SIMPLE_EDGE]
                           SHUFFLE [RS_41]
                             PartitionCols:_col1
-                            Merge Join Operator [MERGEJOIN_333] (rows=633595212 width=88)
+                            Merge Join Operator [MERGEJOIN_326] (rows=633595212 width=88)
                               Conds:RS_38._col0=RS_39._col0(Inner),Output:["_col1","_col2"]
                             <-Map 10 [SIMPLE_EDGE]
                               SHUFFLE [RS_38]
                                 PartitionCols:_col0
                                 Select Operator [SEL_28] (rows=575995635 width=88)
                                   Output:["_col0","_col1","_col2"]
-                                  Filter Operator [FIL_302] (rows=575995635 width=88)
+                                  Filter Operator [FIL_295] (rows=575995635 width=88)
                                     predicate:(ss_hdemo_sk is not null and ss_sold_time_sk is not null and ss_store_sk is not null)
                                     TableScan [TS_26] (rows=575995635 width=88)
                                       default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_time_sk","ss_hdemo_sk","ss_store_sk"]
@@ -282,54 +282,54 @@ Stage-0
                                 PartitionCols:_col0
                                 Select Operator [SEL_31] (rows=14400 width=471)
                                   Output:["_col0"]
-                                  Filter Operator [FIL_303] (rows=14400 width=471)
+                                  Filter Operator [FIL_296] (rows=14400 width=471)
                                     predicate:((t_hour = 12) and (t_minute < 30) and t_time_sk is not null)
                                     TableScan [TS_29] (rows=86400 width=471)
                                       default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour","t_minute"]
           <-Reducer 22 [SIMPLE_EDGE]
-            SHUFFLE [RS_217]
+            SHUFFLE [RS_210]
               Group By Operator [GBY_76] (rows=1 width=8)
                 Output:["_col0"],aggregations:["count(VALUE._col0)"]
               <-Reducer 21 [SIMPLE_EDGE]
                 SHUFFLE [RS_75]
                   Group By Operator [GBY_74] (rows=1 width=8)
                     Output:["_col0"],aggregations:["count()"]
-                    Merge Join Operator [MERGEJOIN_338] (rows=766650239 width=88)
+                    Merge Join Operator [MERGEJOIN_331] (rows=766650239 width=88)
                       Conds:RS_70._col2=RS_71._col0(Inner)
                     <-Map 25 [SIMPLE_EDGE]
                       SHUFFLE [RS_71]
                         PartitionCols:_col0
                         Select Operator [SEL_63] (rows=852 width=1910)
                           Output:["_col0"]
-                          Filter Operator [FIL_309] (rows=852 width=1910)
+                          Filter Operator [FIL_302] (rows=852 width=1910)
                             predicate:((s_store_name = 'ese') and s_store_sk is not null)
                             TableScan [TS_61] (rows=1704 width=1910)
                               default@store,store,Tbl:COMPLETE,Col:NONE,Output:["s_store_sk","s_store_name"]
                     <-Reducer 20 [SIMPLE_EDGE]
                       SHUFFLE [RS_70]
                         PartitionCols:_col2
-                        Merge Join Operator [MERGEJOIN_337] (rows=696954748 width=88)
+                        Merge Join Operator [MERGEJOIN_330] (rows=696954748 width=88)
                           Conds:RS_67._col1=RS_68._col0(Inner),Output:["_col2"]
                         <-Map 24 [SIMPLE_EDGE]
                           SHUFFLE [RS_68]
                             PartitionCols:_col0
                             Select Operator [SEL_60] (rows=3600 width=107)
                               Output:["_col0"]
-                              Filter Operator [FIL_308] (rows=3600 width=107)
+                              Filter Operator [FIL_301] (rows=3600 width=107)
                                 predicate:((((hd_dep_count = 3) and (hd_vehicle_count <= 5)) or ((hd_dep_count = 0) and (hd_vehicle_count <= 2)) or ((hd_dep_count = 1) and (hd_vehicle_count <= 3))) and hd_demo_sk is not null)
                                 TableScan [TS_58] (rows=7200 width=107)
                                   default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count","hd_vehicle_count"]
                         <-Reducer 19 [SIMPLE_EDGE]
                           SHUFFLE [RS_67]
                             PartitionCols:_col1
-                            Merge Join Operator [MERGEJOIN_336] (rows=633595212 width=88)
+                            Merge Join Operator [MERGEJOIN_329] (rows=633595212 width=88)
                               Conds:RS_64._col0=RS_65._col0(Inner),Output:["_col1","_col2"]
                             <-Map 18 [SIMPLE_EDGE]
                               SHUFFLE [RS_64]
                                 PartitionCols:_col0
                                 Select Operator [SEL_54] (rows=575995635 width=88)
                                   Output:["_col0","_col1","_col2"]
-                                  Filter Operator [FIL_306] (rows=575995635 width=88)
+                                  Filter Operator [FIL_299] (rows=575995635 width=88)
                                     predicate:(ss_hdemo_sk is not null and ss_sold_time_sk is not null and ss_store_sk is not null)
                                     TableScan [TS_52] (rows=575995635 width=88)
                                       default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_time_sk","ss_hdemo_sk","ss_store_sk"]
@@ -338,54 +338,54 @@ Stage-0
                                 PartitionCols:_col0
                                 Select Operator [SEL_57] (rows=14400 width=471)
                                   Output:["_col0"]
-                                  Filter Operator [FIL_307] (rows=14400 width=471)
+                                  Filter Operator [FIL_300] (rows=14400 width=471)
                                     predicate:((t_hour = 11) and (t_minute >= 30) and t_time_sk is not null)
                                     TableScan [TS_55] (rows=86400 width=471)
                                       default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour","t_minute"]
           <-Reducer 30 [SIMPLE_EDGE]
-            SHUFFLE [RS_218]
+            SHUFFLE [RS_211]
               Group By Operator [GBY_102] (rows=1 width=8)
                 Output:["_col0"],aggregations:["count(VALUE._col0)"]
               <-Reducer 29 [SIMPLE_EDGE]
                 SHUFFLE [RS_101]
                   Group By Operator [GBY_100] (rows=1 width=8)
                     Output:["_col0"],aggregations:["count()"]
-                    Merge Join Operator [MERGEJOIN_341] (rows=766650239 width=88)
+                    Merge Join Operator [MERGEJOIN_334] (rows=766650239 width=88)
                       Conds:RS_96._col2=RS_97._col0(Inner)
                     <-Map 33 [SIMPLE_EDGE]
                       SHUFFLE [RS_97]
                         PartitionCols:_col0
                         Select Operator [SEL_89] (rows=852 width=1910)
                           Output:["_col0"]
-                          Filter Operator [FIL_313] (rows=852 width=1910)
+                          Filter Operator [FIL_306] (rows=852 width=1910)
                             predicate:((s_store_name = 'ese') and s_store_sk is not null)
                             TableScan [TS_87] (rows=1704 width=1910)
                               default@store,store,Tbl:COMPLETE,Col:NONE,Output:["s_store_sk","s_store_name"]
                     <-Reducer 28 [SIMPLE_EDGE]
                       SHUFFLE [RS_96]
                         PartitionCols:_col2
-                        Merge Join Operator [MERGEJOIN_340] (rows=696954748 width=88)
+                        Merge Join Operator [MERGEJOIN_333] (rows=696954748 width=88)
                           Conds:RS_93._col1=RS_94._col0(Inner),Output:["_col2"]
                         <-Map 32 [SIMPLE_EDGE]
                           SHUFFLE [RS_94]
                             PartitionCols:_col0
                             Select Operator [SEL_86] (rows=3600 width=107)
                               Output:["_col0"]
-                              Filter Operator [FIL_312] (rows=3600 width=107)
+                              Filter Operator [FIL_305] (rows=3600 width=107)
                                 predicate:((((hd_dep_count = 3) and (hd_vehicle_count <= 5)) or ((hd_dep_count = 0) and (hd_vehicle_count <= 2)) or ((hd_dep_count = 1) and (hd_vehicle_count <= 3))) and hd_demo_sk is not null)
                                 TableScan [TS_84] (rows=7200 width=107)
                                   default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count","hd_vehicle_count"]
                         <-Reducer 27 [SIMPLE_EDGE]
                           SHUFFLE [RS_93]
                             PartitionCols:_col1
-                            Merge Join Operator [MERGEJOIN_339] (rows=633595212 width=88)
+                            Merge Join Operator [MERGEJOIN_332] (rows=633595212 width=88)
                               Conds:RS_90._col0=RS_91._col0(Inner),Output:["_col1","_col2"]
                             <-Map 26 [SIMPLE_EDGE]
                               SHUFFLE [RS_90]
                                 PartitionCols:_col0
                                 Select Operator [SEL_80] (rows=575995635 width=88)
                                   Output:["_col0","_col1","_col2"]
-                                  Filter Operator [FIL_310] (rows=575995635 width=88)
+                                  Filter Operator [FIL_303] (rows=575995635 width=88)
                                     predicate:(ss_hdemo_sk is not null and ss_sold_time_sk is not null and ss_store_sk is not null)
                                     TableScan [TS_78] (rows=575995635 width=88)
                                       default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_time_sk","ss_hdemo_sk","ss_store_sk"]
@@ -394,54 +394,54 @@ Stage-0
                                 PartitionCols:_col0
                                 Select Operator [SEL_83] (rows=14400 width=471)
                                   Output:["_col0"]
-                                  Filter Operator [FIL_311] (rows=14400 width=471)
+                                  Filter Operator [FIL_304] (rows=14400 width=471)
                                     predicate:((t_hour = 11) and (t_minute < 30) and t_time_sk is not null)
                                     TableScan [TS_81] (rows=86400 width=471)
                                       default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour","t_minute"]
           <-Reducer 38 [SIMPLE_EDGE]
-            SHUFFLE [RS_219]
+            SHUFFLE [RS_212]
               Group By Operator [GBY_128] (rows=1 width=8)
                 Output:["_col0"],aggregations:["count(VALUE._col0)"]
               <-Reducer 37 [SIMPLE_EDGE]
                 SHUFFLE [RS_127]
                   Group By Operator [GBY_126] (rows=1 width=8)
                     Output:["_col0"],aggregations:["count()"]
-                    Merge Join Operator [MERGEJOIN_344] (rows=766650239 width=88)
+                    Merge Join Operator [MERGEJOIN_337] (rows=766650239 width=88)
                       Conds:RS_122._col2=RS_123._col0(Inner)
                     <-Map 41 [SIMPLE_EDGE]
                       SHUFFLE [RS_123]
                         PartitionCols:_col0
                         Select Operator [SEL_115] (rows=852 width=1910)
                           Output:["_col0"]
-                          Filter Operator [FIL_317] (rows=852 width=1910)
+                          Filter Operator [FIL_310] (rows=852 width=1910)
                             predicate:((s_store_name = 'ese') and s_store_sk is not null)
                             TableScan [TS_113] (rows=1704 width=1910)
                               default@store,store,Tbl:COMPLETE,Col:NONE,Output:["s_store_sk","s_store_name"]
                     <-Reducer 36 [SIMPLE_EDGE]
                       SHUFFLE [RS_122]
                         PartitionCols:_col2
-                        Merge Join Operator [MERGEJOIN_343] (rows=696954748 width=88)
+                        Merge Join Operator [MERGEJOIN_336] (rows=696954748 width=88)
                           Conds:RS_119._col1=RS_120._col0(Inner),Output:["_col2"]
                         <-Map 40 [SIMPLE_EDGE]
                           SHUFFLE [RS_120]
                             PartitionCols:_col0
                             Select Operator [SEL_112] (rows=3600 width=107)
                               Output:["_col0"]
-                              Filter Operator [FIL_316] (rows=3600 width=107)
+                              Filter Operator [FIL_309] (rows=3600 width=107)
                                 predicate:((((hd_dep_count = 3) and (hd_vehicle_count <= 5)) or ((hd_dep_count = 0) and (hd_vehicle_count <= 2)) or ((hd_dep_count = 1) and (hd_vehicle_count <= 3))) and hd_demo_sk is not null)
                                 TableScan [TS_110] (rows=7200 width=107)
                                   default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count","hd_vehicle_count"]
                         <-Reducer 35 [SIMPLE_EDGE]
                           SHUFFLE [RS_119]
                             PartitionCols:_col1
-                            Merge Join Operator [MERGEJOIN_342] (rows=633595212 width=88)
+                            Merge Join Operator [MERGEJOIN_335] (rows=633595212 width=88)
                               Conds:RS_116._col0=RS_117._col0(Inner),Output:["_col1","_col2"]
                             <-Map 34 [SIMPLE_EDGE]
                               SHUFFLE [RS_116]
                                 PartitionCols:_col0
                                 Select Operator [SEL_106] (rows=575995635 width=88)
                                   Output:["_col0","_col1","_col2"]
-                                  Filter Operator [FIL_314] (rows=575995635 width=88)
+                                  Filter Operator [FIL_307] (rows=575995635 width=88)
                                     predicate:(ss_hdemo_sk is not null and ss_sold_time_sk is not null and ss_store_sk is not null)
                                     TableScan [TS_104] (rows=575995635 width=88)
                                       default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_time_sk","ss_hdemo_sk","ss_store_sk"]
@@ -450,54 +450,54 @@ Stage-0
                                 PartitionCols:_col0
                                 Select Operator [SEL_109] (rows=14400 width=471)
                                   Output:["_col0"]
-                                  Filter Operator [FIL_315] (rows=14400 width=471)
+                                  Filter Operator [FIL_308] (rows=14400 width=471)
                                     predicate:((t_hour = 10) and (t_minute >= 30) and t_time_sk is not null)
                                     TableScan [TS_107] (rows=86400 width=471)
                                       default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour","t_minute"]
           <-Reducer 46 [SIMPLE_EDGE]
-            SHUFFLE [RS_220]
+            SHUFFLE [RS_213]
               Group By Operator [GBY_154] (rows=1 width=8)
                 Output:["_col0"],aggregations:["count(VALUE._col0)"]
               <-Reducer 45 [SIMPLE_EDGE]
                 SHUFFLE [RS_153]
                   Group By Operator [GBY_152] (rows=1 width=8)
                     Output:["_col0"],aggregations:["count()"]
-                    Merge Join Operator [MERGEJOIN_347] (rows=766650239 width=88)
+                    Merge Join Operator [MERGEJOIN_340] (rows=766650239 width=88)
                       Conds:RS_148._col2=RS_149._col0(Inner)
                     <-Map 49 [SIMPLE_EDGE]
                       SHUFFLE [RS_149]
                         PartitionCols:_col0
                         Select Operator [SEL_141] (rows=852 width=1910)
                           Output:["_col0"]
-                          Filter Operator [FIL_321] (rows=852 width=1910)
+                          Filter Operator [FIL_314] (rows=852 width=1910)
                             predicate:((s_store_name = 'ese') and s_store_sk is not null)
                             TableScan [TS_139] (rows=1704 width=1910)
                               default@store,store,Tbl:COMPLETE,Col:NONE,Output:["s_store_sk","s_store_name"]
                     <-Reducer 44 [SIMPLE_EDGE]
                       SHUFFLE [RS_148]
                         PartitionCols:_col2
-                        Merge Join Operator [MERGEJOIN_346] (rows=696954748 width=88)
+                        Merge Join Operator [MERGEJOIN_339] (rows=696954748 width=88)
                           Conds:RS_145._col1=RS_146._col0(Inner),Output:["_col2"]
                         <-Map 48 [SIMPLE_EDGE]
                           SHUFFLE [RS_146]
                             PartitionCols:_col0
                             Select Operator [SEL_138] (rows=3600 width=107)
                               Output:["_col0"]
-                              Filter Operator [FIL_320] (rows=3600 width=107)
+                              Filter Operator [FIL_313] (rows=3600 width=107)
                                 predicate:((((hd_dep_count = 3) and (hd_vehicle_count <= 5)) or ((hd_dep_count = 0) and (hd_vehicle_count <= 2)) or ((hd_dep_count = 1) and (hd_vehicle_count <= 3))) and hd_demo_sk is not null)
                                 TableScan [TS_136] (rows=7200 width=107)
                                   default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count","hd_vehicle_count"]
                         <-Reducer 43 [SIMPLE_EDGE]
                           SHUFFLE [RS_145]
                             PartitionCols:_col1
-                            Merge Join Operator [MERGEJOIN_345] (rows=633595212 width=88)
+                            Merge Join Operator [MERGEJOIN_338] (rows=633595212 width=88)
                               Conds:RS_142._col0=RS_143._col0(Inner),Output:["_col1","_col2"]
                             <-Map 42 [SIMPLE_EDGE]
                               SHUFFLE [RS_142]
                                 PartitionCols:_col0
                                 Select Operator [SEL_132] (rows=575995635 width=88)
                                   Output:["_col0","_col1","_col2"]
-                                  Filter Operator [FIL_318] (rows=575995635 width=88)
+                                  Filter Operator [FIL_311] (rows=575995635 width=88)
                                     predicate:(ss_hdemo_sk is not null and ss_sold_time_sk is not null and ss_store_sk is not null)
                                     TableScan [TS_130] (rows=575995635 width=88)
                                       default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_time_sk","ss_hdemo_sk","ss_store_sk"]
@@ -506,54 +506,54 @@ Stage-0
                                 PartitionCols:_col0
                                 Select Operator [SEL_135] (rows=14400 width=471)
                                   Output:["_col0"]
-                                  Filter Operator [FIL_319] (rows=14400 width=471)
+                                  Filter Operator [FIL_312] (rows=14400 width=471)
                                     predicate:((t_hour = 10) and (t_minute < 30) and t_time_sk is not null)
                                     TableScan [TS_133] (rows=86400 width=471)
                                       default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour","t_minute"]
           <-Reducer 5 [SIMPLE_EDGE]
-            SHUFFLE [RS_215]
+            SHUFFLE [RS_208]
               Group By Operator [GBY_24] (rows=1 width=8)
                 Output:["_col0"],aggregations:["count(VALUE._col0)"]
               <-Reducer 4 [SIMPLE_EDGE]
                 SHUFFLE [RS_23]
                   Group By Operator [GBY_22] (rows=1 width=8)
                     Output:["_col0"],aggregations:["count()"]
-                    Merge Join Operator [MERGEJOIN_332] (rows=766650239 width=88)
+                    Merge Join Operator [MERGEJOIN_325] (rows=766650239 width=88)
                       Conds:RS_18._col2=RS_19._col0(Inner)
                     <-Map 9 [SIMPLE_EDGE]
                       SHUFFLE [RS_19]
                         PartitionCols:_col0
                         Select Operator [SEL_11] (rows=852 width=1910)
                           Output:["_col0"]
-                          Filter Operator [FIL_301] (rows=852 width=1910)
+                          Filter Operator [FIL_294] (rows=852 width=1910)
                             predicate:((s_store_name = 'ese') and s_store_sk is not null)
                             TableScan [TS_9] (rows=1704 width=1910)
                               default@store,store,Tbl:COMPLETE,Col:NONE,Output:["s_store_sk","s_store_name"]
                     <-Reducer 3 [SIMPLE_EDGE]
                       SHUFFLE [RS_18]
                         PartitionCols:_col2
-                        Merge Join Operator [MERGEJOIN_331] (rows=696954748 width=88)
+                        Merge Join Operator [MERGEJOIN_324] (rows=696954748 width=88)
                           Conds:RS_15._col1=RS_16._col0(Inner),Output:["_col2"]
                         <-Map 8 [SIMPLE_EDGE]
                           SHUFFLE [RS_16]
                             PartitionCols:_col0
                             Select Operator [SEL_8] (rows=3600 width=107)
                               Output:["_col0"]
-                              Filter Operator [FIL_300] (rows=3600 width=107)
+                              Filter Operator [FIL_293] (rows=3600 width=107)
                                 predicate:((((hd_dep_count = 3) and (hd_vehicle_count <= 5)) or ((hd_dep_count = 0) and (hd_vehicle_count <= 2)) or ((hd_dep_count = 1) and (hd_vehicle_count <= 3))) and hd_demo_sk is not null)
                                 TableScan [TS_6] (rows=7200 width=107)
                                   default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count","hd_vehicle_count"]
                         <-Reducer 2 [SIMPLE_EDGE]
                           SHUFFLE [RS_15]
                             PartitionCols:_col1
-                            Merge Join Operator [MERGEJOIN_330] (rows=633595212 width=88)
+                            Merge Join Operator [MERGEJOIN_323] (rows=633595212 width=88)
                               Conds:RS_12._col0=RS_13._col0(Inner),Output:["_col1","_col2"]
                             <-Map 1 [SIMPLE_EDGE]
                               SHUFFLE [RS_12]
                                 PartitionCols:_col0
                                 Select Operator [SEL_2] (rows=575995635 width=88)
                                   Output:["_col0","_col1","_col2"]
-                                  Filter Operator [FIL_298] (rows=575995635 width=88)
+                                  Filter Operator [FIL_291] (rows=575995635 width=88)
                                     predicate:(ss_hdemo_sk is not null and ss_sold_time_sk is not null and ss_store_sk is not null)
                                     TableScan [TS_0] (rows=575995635 width=88)
                                       default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_time_sk","ss_hdemo_sk","ss_store_sk"]
@@ -562,54 +562,54 @@ Stage-0
                                 PartitionCols:_col0
                                 Select Operator [SEL_5] (rows=14400 width=471)
                                   Output:["_col0"]
-                                  Filter Operator [FIL_299] (rows=14400 width=471)
+                                  Filter Operator [FIL_292] (rows=14400 width=471)
                                     predicate:((t_hour = 8) and (t_minute >= 30) and t_time_sk is not null)
                                     TableScan [TS_3] (rows=86400 width=471)
                                       default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour","t_minute"]
           <-Reducer 54 [SIMPLE_EDGE]
-            SHUFFLE [RS_221]
+            SHUFFLE [RS_214]
               Group By Operator [GBY_180] (rows=1 width=8)
                 Output:["_col0"],aggregations:["count(VALUE._col0)"]
               <-Reducer 53 [SIMPLE_EDGE]
                 SHUFFLE [RS_179]
                   Group By Operator [GBY_178] (rows=1 width=8)
                     Output:["_col0"],aggregations:["count()"]
-                    Merge Join Operator [MERGEJOIN_350] (rows=766650239 width=88)
+                    Merge Join Operator [MERGEJOIN_343] (rows=766650239 width=88)
                       Conds:RS_174._col2=RS_175._col0(Inner)
                     <-Map 57 [SIMPLE_EDGE]
                       SHUFFLE [RS_175]
                         PartitionCols:_col0
                         Select Operator [SEL_167] (rows=852 width=1910)
                           Output:["_col0"]
-                          Filter Operator [FIL_325] (rows=852 width=1910)
+                          Filter Operator [FIL_318] (rows=852 width=1910)
                             predicate:((s_store_name = 'ese') and s_store_sk is not null)
                             TableScan [TS_165] (rows=1704 width=1910)
                               default@store,store,Tbl:COMPLETE,Col:NONE,Output:["s_store_sk","s_store_name"]
                     <-Reducer 52 [SIMPLE_EDGE]
                       SHUFFLE [RS_174]
                         PartitionCols:_col2
-                        Merge Join Operator [MERGEJOIN_349] (rows=696954748 width=88)
+                        Merge Join Operator [MERGEJOIN_342] (rows=696954748 width=88)
                           Conds:RS_171._col1=RS_172._col0(Inner),Output:["_col2"]
                         <-Map 56 [SIMPLE_EDGE]
                           SHUFFLE [RS_172]
                             PartitionCols:_col0
                             Select Operator [SEL_164] (rows=3600 width=107)
                               Output:["_col0"]
-                              Filter Operator [FIL_324] (rows=3600 width=107)
+                              Filter Operator [FIL_317] (rows=3600 width=107)
                                 predicate:((((hd_dep_count = 3) and (hd_vehicle_count <= 5)) or ((hd_dep_count = 0) and (hd_vehicle_count <= 2)) or ((hd_dep_count = 1) and (hd_vehicle_count <= 3))) and hd_demo_sk is not null)
                                 TableScan [TS_162] (rows=7200 width=107)
                                   default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count","hd_vehicle_count"]
                         <-Reducer 51 [SIMPLE_EDGE]
                           SHUFFLE [RS_171]
                             PartitionCols:_col1
-                            Merge Join Operator [MERGEJOIN_348] (rows=633595212 width=88)
+                            Merge Join Operator [MERGEJOIN_341] (rows=633595212 width=88)
                               Conds:RS_168._col0=RS_169._col0(Inner),Output:["_col1","_col2"]
                             <-Map 50 [SIMPLE_EDGE]
                               SHUFFLE [RS_168]
                                 PartitionCols:_col0
                                 Select Operator [SEL_158] (rows=575995635 width=88)
                                   Output:["_col0","_col1","_col2"]
-                                  Filter Operator [FIL_322] (rows=575995635 width=88)
+                                  Filter Operator [FIL_315] (rows=575995635 width=88)
                                     predicate:(ss_hdemo_sk is not null and ss_sold_time_sk is not null and ss_store_sk is not null)
                                     TableScan [TS_156] (rows=575995635 width=88)
                                       default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_time_sk","ss_hdemo_sk","ss_store_sk"]
@@ -618,54 +618,54 @@ Stage-0
                                 PartitionCols:_col0
                                 Select Operator [SEL_161] (rows=14400 width=471)
                                   Output:["_col0"]
-                                  Filter Operator [FIL_323] (rows=14400 width=471)
+                                  Filter Operator [FIL_316] (rows=14400 width=471)
                                     predicate:((t_hour = 9) and (t_minute >= 30) and t_time_sk is not null)
                                     TableScan [TS_159] (rows=86400 width=471)
                                       default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour","t_minute"]
           <-Reducer 62 [SIMPLE_EDGE]
-            SHUFFLE [RS_222]
+            SHUFFLE [RS_215]
               Group By Operator [GBY_206] (rows=1 width=8)
                 Output:["_col0"],aggregations:["count(VALUE._col0)"]
               <-Reducer 61 [SIMPLE_EDGE]
                 SHUFFLE [RS_205]
                   Group By Operator [GBY_204] (rows=1 width=8)
                     Output:["_col0"],aggregations:["count()"]
-                    Merge Join Operator [MERGEJOIN_353] (rows=766650239 width=88)
+                    Merge Join Operator [MERGEJOIN_346] (rows=766650239 width=88)
                       Conds:RS_200._col2=RS_201._col0(Inner)
                     <-Map 65 [SIMPLE_EDGE]
                       SHUFFLE [RS_201]
                         PartitionCols:_col0
                         Select Operator [SEL_193] (rows=852 width=1910)
                           Output:["_col0"]
-                          Filter Operator [FIL_329] (rows=852 width=1910)
+                          Filter Operator [FIL_322] (rows=852 width=1910)
                             predicate:((s_store_name = 'ese') and s_store_sk is not null)
                             TableScan [TS_191] (rows=1704 width=1910)
                               default@store,store,Tbl:COMPLETE,Col:NONE,Output:["s_store_sk","s_store_name"]
                     <-Reducer 60 [SIMPLE_EDGE]
                       SHUFFLE [RS_200]
                         PartitionCols:_col2
-                        Merge Join Operator [MERGEJOIN_352] (rows=696954748 width=88)
+                        Merge Join Operator [MERGEJOIN_345] (rows=696954748 width=88)
                           Conds:RS_197._col1=RS_198._col0(Inner),Output:["_col2"]
                         <-Map 64 [SIMPLE_EDGE]
                           SHUFFLE [RS_198]
                             PartitionCols:_col0
                             Select Operator [SEL_190] (rows=3600 width=107)
                               Output:["_col0"]
-                              Filter Operator [FIL_328] (rows=3600 width=107)
+                              Filter Operator [FIL_321] (rows=3600 width=107)
                                 predicate:((((hd_dep_count = 3) and (hd_vehicle_count <= 5)) or ((hd_dep_count = 0) and (hd_vehicle_count <= 2)) or ((hd_dep_count = 1) and (hd_vehicle_count <= 3))) and hd_demo_sk is not null)
                                 TableScan [TS_188] (rows=7200 width=107)
                                   default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count","hd_vehicle_count"]
                         <-Reducer 59 [SIMPLE_EDGE]
                           SHUFFLE [RS_197]
                             PartitionCols:_col1
-                            Merge Join Operator [MERGEJOIN_351] (rows=633595212 width=88)
+                            Merge Join Operator [MERGEJOIN_344] (rows=633595212 width=88)
                               Conds:RS_194._col0=RS_195._col0(Inner),Output:["_col1","_col2"]
                             <-Map 58 [SIMPLE_EDGE]
                               SHUFFLE [RS_194]
                                 PartitionCols:_col0
                                 Select Operator [SEL_184] (rows=575995635 width=88)
                                   Output:["_col0","_col1","_col2"]
-                                  Filter Operator [FIL_326] (rows=575995635 width=88)
+                                  Filter Operator [FIL_319] (rows=575995635 width=88)
                                     predicate:(ss_hdemo_sk is not null and ss_sold_time_sk is not null and ss_store_sk is not null)
                                     TableScan [TS_182] (rows=575995635 width=88)
                                       default@store_sales,store_sales,Tbl:COMPLETE,Col:NONE,Output:["ss_sold_time_sk","ss_hdemo_sk","ss_store_sk"]
@@ -674,7 +674,7 @@ Stage-0
                                 PartitionCols:_col0
                                 Select Operator [SEL_187] (rows=14400 width=471)
                                   Output:["_col0"]
-                                  Filter Operator [FIL_327] (rows=14400 width=471)
+                                  Filter Operator [FIL_320] (rows=14400 width=471)
                                     predicate:((t_hour = 9) and (t_minute < 30) and t_time_sk is not null)
                                     TableScan [TS_185] (rows=86400 width=471)
                                       default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour","t_minute"]

http://git-wip-us.apache.org/repos/asf/hive/blob/10423f51/ql/src/test/results/clientpositive/perf/query90.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/perf/query90.q.out b/ql/src/test/results/clientpositive/perf/query90.q.out
index eea2a06..7108931 100644
--- a/ql/src/test/results/clientpositive/perf/query90.q.out
+++ b/ql/src/test/results/clientpositive/perf/query90.q.out
@@ -1,4 +1,4 @@
-Warning: Shuffle Join MERGEJOIN[93][tables = [$hdt$_0, $hdt$_1]] in Stage 'Reducer 6' is a cross product
+Warning: Shuffle Join MERGEJOIN[92][tables = [$hdt$_0, $hdt$_1]] in Stage 'Reducer 6' is a cross product
 PREHOOK: query: explain select cast(amc as decimal(15,4))/cast(pmc as decimal(15,4)) am_pm_ratio from ( select count(*) amc from web_sales, household_demographics , time_dim, web_page where ws_sold_time_sk = time_dim.t_time_sk and ws_ship_hdemo_sk = household_demographics.hd_demo_sk and ws_web_page_sk = web_page.wp_web_page_sk and time_dim.t_hour between 6 and 6+1 and household_demographics.hd_dep_count = 8 and web_page.wp_char_count between 5000 and 5200) at, ( select count(*) pmc from web_sales, household_demographics , time_dim, web_page where ws_sold_time_sk = time_dim.t_time_sk and ws_ship_hdemo_sk = household_demographics.hd_demo_sk and ws_web_page_sk = web_page.wp_web_page_sk and time_dim.t_hour between 14 and 14+1 and household_demographics.hd_dep_count = 8 and web_page.wp_char_count between 5000 and 5200) pt order by am_pm_ratio limit 100
 PREHOOK: type: QUERY
 POSTHOOK: query: explain select cast(amc as decimal(15,4))/cast(pmc as decimal(15,4)) am_pm_ratio from ( select count(*) amc from web_sales, household_demographics , time_dim, web_page where ws_sold_time_sk = time_dim.t_time_sk and ws_ship_hdemo_sk = household_demographics.hd_demo_sk and ws_web_page_sk = web_page.wp_web_page_sk and time_dim.t_hour between 6 and 6+1 and household_demographics.hd_dep_count = 8 and web_page.wp_char_count between 5000 and 5200) at, ( select count(*) pmc from web_sales, household_demographics , time_dim, web_page where ws_sold_time_sk = time_dim.t_time_sk and ws_ship_hdemo_sk = household_demographics.hd_demo_sk and ws_web_page_sk = web_page.wp_web_page_sk and time_dim.t_hour between 14 and 14+1 and household_demographics.hd_dep_count = 8 and web_page.wp_char_count between 5000 and 5200) pt order by am_pm_ratio limit 100
@@ -22,61 +22,61 @@ Stage-0
     limit:100
     Stage-1
       Reducer 7
-      File Output Operator [FS_60]
-        Limit [LIM_59] (rows=1 width=8)
+      File Output Operator [FS_59]
+        Limit [LIM_58] (rows=1 width=8)
           Number of rows:100
-          Select Operator [SEL_58] (rows=1 width=8)
+          Select Operator [SEL_57] (rows=1 width=8)
             Output:["_col0"]
           <-Reducer 6 [SIMPLE_EDGE]
-            SHUFFLE [RS_57]
-              Select Operator [SEL_56] (rows=1 width=8)
+            SHUFFLE [RS_56]
+              Select Operator [SEL_55] (rows=1 width=8)
                 Output:["_col0"]
-                Merge Join Operator [MERGEJOIN_93] (rows=1 width=8)
+                Merge Join Operator [MERGEJOIN_92] (rows=1 width=8)
                   Conds:(Inner),Output:["_col0","_col1"]
                 <-Reducer 15 [SIMPLE_EDGE]
-                  SHUFFLE [RS_54]
+                  SHUFFLE [RS_53]
                     Group By Operator [GBY_50] (rows=1 width=8)
                       Output:["_col0"],aggregations:["count(VALUE._col0)"]
                     <-Reducer 14 [SIMPLE_EDGE]
                       SHUFFLE [RS_49]
                         Group By Operator [GBY_48] (rows=1 width=8)
                           Output:["_col0"],aggregations:["count()"]
-                          Merge Join Operator [MERGEJOIN_92] (rows=191667562 width=135)
+                          Merge Join Operator [MERGEJOIN_91] (rows=191667562 width=135)
                             Conds:RS_44._col1=RS_45._col0(Inner)
                           <-Map 18 [SIMPLE_EDGE]
                             SHUFFLE [RS_45]
                               PartitionCols:_col0
                               Select Operator [SEL_37] (rows=3600 width=107)
                                 Output:["_col0"]
-                                Filter Operator [FIL_86] (rows=3600 width=107)
+                                Filter Operator [FIL_85] (rows=3600 width=107)
                                   predicate:((hd_dep_count = 8) and hd_demo_sk is not null)
                                   TableScan [TS_35] (rows=7200 width=107)
                                     default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count"]
                           <-Reducer 13 [SIMPLE_EDGE]
                             SHUFFLE [RS_44]
                               PartitionCols:_col1
-                              Merge Join Operator [MERGEJOIN_91] (rows=174243235 width=135)
+                              Merge Join Operator [MERGEJOIN_90] (rows=174243235 width=135)
                                 Conds:RS_41._col0=RS_42._col0(Inner),Output:["_col1"]
                               <-Map 17 [SIMPLE_EDGE]
                                 SHUFFLE [RS_42]
                                   PartitionCols:_col0
                                   Select Operator [SEL_34] (rows=43200 width=471)
                                     Output:["_col0"]
-                                    Filter Operator [FIL_85] (rows=43200 width=471)
+                                    Filter Operator [FIL_84] (rows=43200 width=471)
                                       predicate:(t_hour BETWEEN 14 AND 15 and t_time_sk is not null)
                                       TableScan [TS_32] (rows=86400 width=471)
                                         default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour"]
                               <-Reducer 12 [SIMPLE_EDGE]
                                 SHUFFLE [RS_41]
                                   PartitionCols:_col0
-                                  Merge Join Operator [MERGEJOIN_90] (rows=158402938 width=135)
+                                  Merge Join Operator [MERGEJOIN_89] (rows=158402938 width=135)
                                     Conds:RS_38._col2=RS_39._col0(Inner),Output:["_col0","_col1"]
                                   <-Map 11 [SIMPLE_EDGE]
                                     SHUFFLE [RS_38]
                                       PartitionCols:_col2
                                       Select Operator [SEL_28] (rows=144002668 width=135)
                                         Output:["_col0","_col1","_col2"]
-                                        Filter Operator [FIL_83] (rows=144002668 width=135)
+                                        Filter Operator [FIL_82] (rows=144002668 width=135)
                                           predicate:(ws_ship_hdemo_sk is not null and ws_sold_time_sk is not null and ws_web_page_sk is not null)
                                           TableScan [TS_26] (rows=144002668 width=135)
                                             default@web_sales,web_sales,Tbl:COMPLETE,Col:NONE,Output:["ws_sold_time_sk","ws_ship_hdemo_sk","ws_web_page_sk"]
@@ -85,54 +85,54 @@ Stage-0
                                       PartitionCols:_col0
                                       Select Operator [SEL_31] (rows=2301 width=585)
                                         Output:["_col0"]
-                                        Filter Operator [FIL_84] (rows=2301 width=585)
+                                        Filter Operator [FIL_83] (rows=2301 width=585)
                                           predicate:(wp_char_count BETWEEN 5000 AND 5200 and wp_web_page_sk is not null)
                                           TableScan [TS_29] (rows=4602 width=585)
                                             default@web_page,web_page,Tbl:COMPLETE,Col:NONE,Output:["wp_web_page_sk","wp_char_count"]
                 <-Reducer 5 [SIMPLE_EDGE]
-                  SHUFFLE [RS_53]
+                  SHUFFLE [RS_52]
                     Group By Operator [GBY_24] (rows=1 width=8)
                       Output:["_col0"],aggregations:["count(VALUE._col0)"]
                     <-Reducer 4 [SIMPLE_EDGE]
                       SHUFFLE [RS_23]
                         Group By Operator [GBY_22] (rows=1 width=8)
                           Output:["_col0"],aggregations:["count()"]
-                          Merge Join Operator [MERGEJOIN_89] (rows=191667562 width=135)
+                          Merge Join Operator [MERGEJOIN_88] (rows=191667562 width=135)
                             Conds:RS_18._col1=RS_19._col0(Inner)
                           <-Map 10 [SIMPLE_EDGE]
                             SHUFFLE [RS_19]
                               PartitionCols:_col0
                               Select Operator [SEL_11] (rows=3600 width=107)
                                 Output:["_col0"]
-                                Filter Operator [FIL_82] (rows=3600 width=107)
+                                Filter Operator [FIL_81] (rows=3600 width=107)
                                   predicate:((hd_dep_count = 8) and hd_demo_sk is not null)
                                   TableScan [TS_9] (rows=7200 width=107)
                                     default@household_demographics,household_demographics,Tbl:COMPLETE,Col:NONE,Output:["hd_demo_sk","hd_dep_count"]
                           <-Reducer 3 [SIMPLE_EDGE]
                             SHUFFLE [RS_18]
                               PartitionCols:_col1
-                              Merge Join Operator [MERGEJOIN_88] (rows=174243235 width=135)
+                              Merge Join Operator [MERGEJOIN_87] (rows=174243235 width=135)
                                 Conds:RS_15._col0=RS_16._col0(Inner),Output:["_col1"]
                               <-Map 9 [SIMPLE_EDGE]
                                 SHUFFLE [RS_16]
                                   PartitionCols:_col0
                                   Select Operator [SEL_8] (rows=43200 width=471)
                                     Output:["_col0"]
-                                    Filter Operator [FIL_81] (rows=43200 width=471)
+                                    Filter Operator [FIL_80] (rows=43200 width=471)
                                       predicate:(t_hour BETWEEN 6 AND 7 and t_time_sk is not null)
                                       TableScan [TS_6] (rows=86400 width=471)
                                         default@time_dim,time_dim,Tbl:COMPLETE,Col:NONE,Output:["t_time_sk","t_hour"]
                               <-Reducer 2 [SIMPLE_EDGE]
                                 SHUFFLE [RS_15]
                                   PartitionCols:_col0
-                                  Merge Join Operator [MERGEJOIN_87] (rows=158402938 width=135)
+                                  Merge Join Operator [MERGEJOIN_86] (rows=158402938 width=135)
                                     Conds:RS_12._col2=RS_13._col0(Inner),Output:["_col0","_col1"]
                                   <-Map 1 [SIMPLE_EDGE]
                                     SHUFFLE [RS_12]
                                       PartitionCols:_col2
                                       Select Operator [SEL_2] (rows=144002668 width=135)
                                         Output:["_col0","_col1","_col2"]
-                                        Filter Operator [FIL_79] (rows=144002668 width=135)
+                                        Filter Operator [FIL_78] (rows=144002668 width=135)
                                           predicate:(ws_ship_hdemo_sk is not null and ws_sold_time_sk is not null and ws_web_page_sk is not null)
                                           TableScan [TS_0] (rows=144002668 width=135)
                                             default@web_sales,web_sales,Tbl:COMPLETE,Col:NONE,Output:["ws_sold_time_sk","ws_ship_hdemo_sk","ws_web_page_sk"]
@@ -141,7 +141,7 @@ Stage-0
                                       PartitionCols:_col0
                                       Select Operator [SEL_5] (rows=2301 width=585)
                                         Output:["_col0"]
-                                        Filter Operator [FIL_80] (rows=2301 width=585)
+                                        Filter Operator [FIL_79] (rows=2301 width=585)
                                           predicate:(wp_char_count BETWEEN 5000 AND 5200 and wp_web_page_sk is not null)
                                           TableScan [TS_3] (rows=4602 width=585)
                                             default@web_page,web_page,Tbl:COMPLETE,Col:NONE,Output:["wp_web_page_sk","wp_char_count"]

http://git-wip-us.apache.org/repos/asf/hive/blob/10423f51/ql/src/test/results/clientpositive/pointlookup2.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/pointlookup2.q.out b/ql/src/test/results/clientpositive/pointlookup2.q.out
index d0ad68a..5facf9a 100644
--- a/ql/src/test/results/clientpositive/pointlookup2.q.out
+++ b/ql/src/test/results/clientpositive/pointlookup2.q.out
@@ -379,23 +379,27 @@ STAGE PLANS:
             1 _col0 (type: int)
           outputColumnNames: _col0, _col1, _col3, _col4
           Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
-          File Output Operator
-            compressed: false
-            GlobalTableId: 0
+          Select Operator
+            expressions: _col0 (type: int), _col1 (type: string), '2000-04-08' (type: string), _col3 (type: int), _col4 (type: string)
+            outputColumnNames: _col0, _col1, _col2, _col3, _col4
+            Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
+            File Output Operator
+              compressed: false
+              GlobalTableId: 0
 #### A masked pattern was here ####
-            NumFilesPerFileSink: 1
-            table:
-                input format: org.apache.hadoop.mapred.SequenceFileInputFormat
-                output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
-                properties:
-                  columns _col0,_col1,_col3,_col4
-                  columns.types int,string,int,string
-                  escape.delim \
-                  serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
-                serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
-            TotalFiles: 1
-            GatherStats: false
-            MultiFileSpray: false
+              NumFilesPerFileSink: 1
+              table:
+                  input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+                  output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+                  properties:
+                    columns _col0,_col1,_col2,_col3,_col4
+                    columns.types int,string,string,int,string
+                    escape.delim \
+                    serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+                  serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+              TotalFiles: 1
+              GatherStats: false
+              MultiFileSpray: false
 
   Stage: Stage-2
     Map Reduce
@@ -408,7 +412,7 @@ STAGE PLANS:
               sort order: +
               Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
               tag: -1
-              value expressions: _col1 (type: string), _col3 (type: int), _col4 (type: string)
+              value expressions: _col1 (type: string), _col2 (type: string), _col3 (type: int), _col4 (type: string)
               auto parallelism: false
       Path -> Alias:
 #### A masked pattern was here ####
@@ -419,8 +423,8 @@ STAGE PLANS:
             input format: org.apache.hadoop.mapred.SequenceFileInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
             properties:
-              columns _col0,_col1,_col3,_col4
-              columns.types int,string,int,string
+              columns _col0,_col1,_col2,_col3,_col4
+              columns.types int,string,string,int,string
               escape.delim \
               serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
             serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
@@ -428,8 +432,8 @@ STAGE PLANS:
               input format: org.apache.hadoop.mapred.SequenceFileInputFormat
               output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
               properties:
-                columns _col0,_col1,_col3,_col4
-                columns.types int,string,int,string
+                columns _col0,_col1,_col2,_col3,_col4
+                columns.types int,string,string,int,string
                 escape.delim \
                 serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
               serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
@@ -438,7 +442,7 @@ STAGE PLANS:
       Needs Tagging: false
       Reduce Operator Tree:
         Select Operator
-          expressions: KEY.reducesinkkey0 (type: int), VALUE._col0 (type: string), '2000-04-08' (type: string), VALUE._col2 (type: int), VALUE._col3 (type: string), '2000-04-08' (type: string)
+          expressions: KEY.reducesinkkey0 (type: int), VALUE._col0 (type: string), VALUE._col1 (type: string), VALUE._col2 (type: int), VALUE._col3 (type: string), VALUE._col1 (type: string)
           outputColumnNames: _col0, _col1, _col2, _col3, _col4, _col5
           Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
           File Output Operator
@@ -639,23 +643,27 @@ STAGE PLANS:
             1 _col0 (type: int)
           outputColumnNames: _col0, _col1, _col3, _col4
           Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
-          File Output Operator
-            compressed: false
-            GlobalTableId: 0
+          Select Operator
+            expressions: _col0 (type: int), _col1 (type: string), '2000-04-08' (type: string), _col3 (type: int), _col4 (type: string), '2000-04-09' (type: string)
+            outputColumnNames: _col0, _col1, _col2, _col3, _col4, _col5
+            Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
+            File Output Operator
+              compressed: false
+              GlobalTableId: 0
 #### A masked pattern was here ####
-            NumFilesPerFileSink: 1
-            table:
-                input format: org.apache.hadoop.mapred.SequenceFileInputFormat
-                output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
-                properties:
-                  columns _col0,_col1,_col3,_col4
-                  columns.types int,string,int,string
-                  escape.delim \
-                  serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
-                serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
-            TotalFiles: 1
-            GatherStats: false
-            MultiFileSpray: false
+              NumFilesPerFileSink: 1
+              table:
+                  input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+                  output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+                  properties:
+                    columns _col0,_col1,_col2,_col3,_col4,_col5
+                    columns.types int,string,string,int,string,string
+                    escape.delim \
+                    serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+                  serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+              TotalFiles: 1
+              GatherStats: false
+              MultiFileSpray: false
 
   Stage: Stage-2
     Map Reduce
@@ -668,7 +676,7 @@ STAGE PLANS:
               sort order: +
               Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
               tag: -1
-              value expressions: _col1 (type: string), _col3 (type: int), _col4 (type: string)
+              value expressions: _col1 (type: string), _col2 (type: string), _col3 (type: int), _col4 (type: string), _col5 (type: string)
               auto parallelism: false
       Path -> Alias:
 #### A masked pattern was here ####
@@ -679,8 +687,8 @@ STAGE PLANS:
             input format: org.apache.hadoop.mapred.SequenceFileInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
             properties:
-              columns _col0,_col1,_col3,_col4
-              columns.types int,string,int,string
+              columns _col0,_col1,_col2,_col3,_col4,_col5
+              columns.types int,string,string,int,string,string
               escape.delim \
               serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
             serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
@@ -688,8 +696,8 @@ STAGE PLANS:
               input format: org.apache.hadoop.mapred.SequenceFileInputFormat
               output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
               properties:
-                columns _col0,_col1,_col3,_col4
-                columns.types int,string,int,string
+                columns _col0,_col1,_col2,_col3,_col4,_col5
+                columns.types int,string,string,int,string,string
                 escape.delim \
                 serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
               serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
@@ -698,7 +706,7 @@ STAGE PLANS:
       Needs Tagging: false
       Reduce Operator Tree:
         Select Operator
-          expressions: KEY.reducesinkkey0 (type: int), VALUE._col0 (type: string), '2000-04-08' (type: string), VALUE._col2 (type: int), VALUE._col3 (type: string), '2000-04-09' (type: string)
+          expressions: KEY.reducesinkkey0 (type: int), VALUE._col0 (type: string), VALUE._col1 (type: string), VALUE._col2 (type: int), VALUE._col3 (type: string), VALUE._col4 (type: string)
           outputColumnNames: _col0, _col1, _col2, _col3, _col4, _col5
           Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
           File Output Operator
@@ -730,7 +738,7 @@ STAGE PLANS:
       Processor Tree:
         ListSink
 
-Warning: Shuffle Join JOIN[9][tables = [$hdt$_0, $hdt$_1]] in Stage 'Stage-1:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[8][tables = [$hdt$_0, $hdt$_1]] in Stage 'Stage-1:MAPRED' is a cross product
 PREHOOK: query: explain extended
 select *
 from pcr_t1 t1 join pcr_t2 t2
@@ -1032,7 +1040,7 @@ STAGE PLANS:
       Processor Tree:
         ListSink
 
-Warning: Shuffle Join JOIN[9][tables = [$hdt$_0, $hdt$_1]] in Stage 'Stage-1:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[8][tables = [$hdt$_0, $hdt$_1]] in Stage 'Stage-1:MAPRED' is a cross product
 PREHOOK: query: explain extended
 select *
 from pcr_t1 t1 join pcr_t2 t2

http://git-wip-us.apache.org/repos/asf/hive/blob/10423f51/ql/src/test/results/clientpositive/pointlookup3.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/pointlookup3.q.out b/ql/src/test/results/clientpositive/pointlookup3.q.out
index 39804cf..def1bc8 100644
--- a/ql/src/test/results/clientpositive/pointlookup3.q.out
+++ b/ql/src/test/results/clientpositive/pointlookup3.q.out
@@ -305,7 +305,7 @@ STAGE PLANS:
       Needs Tagging: false
       Reduce Operator Tree:
         Select Operator
-          expressions: KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: string), KEY.reducesinkkey2 (type: string), '2001-04-08' (type: string)
+          expressions: KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: string), KEY.reducesinkkey2 (type: string), KEY.reducesinkkey3 (type: string)
           outputColumnNames: _col0, _col1, _col2, _col3
           Statistics: Num rows: 10 Data size: 80 Basic stats: COMPLETE Column stats: NONE
           File Output Operator
@@ -461,23 +461,27 @@ STAGE PLANS:
             1 _col0 (type: int)
           outputColumnNames: _col0, _col1, _col3, _col4, _col5, _col6
           Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
-          File Output Operator
-            compressed: false
-            GlobalTableId: 0
+          Select Operator
+            expressions: _col0 (type: int), _col1 (type: string), '2000-04-08' (type: string), _col3 (type: string), _col4 (type: int), _col5 (type: string), _col6 (type: string), '2001-04-08' (type: string)
+            outputColumnNames: _col0, _col1, _col2, _col3, _col4, _col5, _col6, _col7
+            Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
+            File Output Operator
+              compressed: false
+              GlobalTableId: 0
 #### A masked pattern was here ####
-            NumFilesPerFileSink: 1
-            table:
-                input format: org.apache.hadoop.mapred.SequenceFileInputFormat
-                output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
-                properties:
-                  columns _col0,_col1,_col3,_col4,_col5,_col6
-                  columns.types int,string,string,int,string,string
-                  escape.delim \
-                  serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
-                serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
-            TotalFiles: 1
-            GatherStats: false
-            MultiFileSpray: false
+              NumFilesPerFileSink: 1
+              table:
+                  input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+                  output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+                  properties:
+                    columns _col0,_col1,_col2,_col3,_col4,_col5,_col6,_col7
+                    columns.types int,string,string,string,int,string,string,string
+                    escape.delim \
+                    serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+                  serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+              TotalFiles: 1
+              GatherStats: false
+              MultiFileSpray: false
 
   Stage: Stage-2
     Map Reduce
@@ -490,7 +494,7 @@ STAGE PLANS:
               sort order: +
               Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
               tag: -1
-              value expressions: _col1 (type: string), _col3 (type: string), _col4 (type: int), _col5 (type: string), _col6 (type: string)
+              value expressions: _col1 (type: string), _col2 (type: string), _col3 (type: string), _col4 (type: int), _col5 (type: string), _col6 (type: string), _col7 (type: string)
               auto parallelism: false
       Path -> Alias:
 #### A masked pattern was here ####
@@ -501,8 +505,8 @@ STAGE PLANS:
             input format: org.apache.hadoop.mapred.SequenceFileInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
             properties:
-              columns _col0,_col1,_col3,_col4,_col5,_col6
-              columns.types int,string,string,int,string,string
+              columns _col0,_col1,_col2,_col3,_col4,_col5,_col6,_col7
+              columns.types int,string,string,string,int,string,string,string
               escape.delim \
               serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
             serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
@@ -510,8 +514,8 @@ STAGE PLANS:
               input format: org.apache.hadoop.mapred.SequenceFileInputFormat
               output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
               properties:
-                columns _col0,_col1,_col3,_col4,_col5,_col6
-                columns.types int,string,string,int,string,string
+                columns _col0,_col1,_col2,_col3,_col4,_col5,_col6,_col7
+                columns.types int,string,string,string,int,string,string,string
                 escape.delim \
                 serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
               serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
@@ -520,7 +524,7 @@ STAGE PLANS:
       Needs Tagging: false
       Reduce Operator Tree:
         Select Operator
-          expressions: KEY.reducesinkkey0 (type: int), VALUE._col0 (type: string), '2000-04-08' (type: string), VALUE._col2 (type: string), VALUE._col3 (type: int), VALUE._col4 (type: string), VALUE._col5 (type: string), '2001-04-08' (type: string)
+          expressions: KEY.reducesinkkey0 (type: int), VALUE._col0 (type: string), VALUE._col1 (type: string), VALUE._col2 (type: string), VALUE._col3 (type: int), VALUE._col4 (type: string), VALUE._col5 (type: string), VALUE._col6 (type: string)
           outputColumnNames: _col0, _col1, _col2, _col3, _col4, _col5, _col6, _col7
           Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
           File Output Operator
@@ -723,23 +727,27 @@ STAGE PLANS:
             1 _col0 (type: int)
           outputColumnNames: _col0, _col1, _col3, _col4, _col5, _col7
           Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
-          File Output Operator
-            compressed: false
-            GlobalTableId: 0
+          Select Operator
+            expressions: _col0 (type: int), _col1 (type: string), '2000-04-08' (type: string), _col3 (type: string), _col4 (type: int), _col5 (type: string), '2000-04-09' (type: string), _col7 (type: string)
+            outputColumnNames: _col0, _col1, _col2, _col3, _col4, _col5, _col6, _col7
+            Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
+            File Output Operator
+              compressed: false
+              GlobalTableId: 0
 #### A masked pattern was here ####
-            NumFilesPerFileSink: 1
-            table:
-                input format: org.apache.hadoop.mapred.SequenceFileInputFormat
-                output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
-                properties:
-                  columns _col0,_col1,_col3,_col4,_col5,_col7
-                  columns.types int,string,string,int,string,string
-                  escape.delim \
-                  serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
-                serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
-            TotalFiles: 1
-            GatherStats: false
-            MultiFileSpray: false
+              NumFilesPerFileSink: 1
+              table:
+                  input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+                  output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+                  properties:
+                    columns _col0,_col1,_col2,_col3,_col4,_col5,_col6,_col7
+                    columns.types int,string,string,string,int,string,string,string
+                    escape.delim \
+                    serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+                  serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+              TotalFiles: 1
+              GatherStats: false
+              MultiFileSpray: false
 
   Stage: Stage-2
     Map Reduce
@@ -752,7 +760,7 @@ STAGE PLANS:
               sort order: +
               Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
               tag: -1
-              value expressions: _col1 (type: string), _col3 (type: string), _col4 (type: int), _col5 (type: string), _col7 (type: string)
+              value expressions: _col1 (type: string), _col2 (type: string), _col3 (type: string), _col4 (type: int), _col5 (type: string), _col6 (type: string), _col7 (type: string)
               auto parallelism: false
       Path -> Alias:
 #### A masked pattern was here ####
@@ -763,8 +771,8 @@ STAGE PLANS:
             input format: org.apache.hadoop.mapred.SequenceFileInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
             properties:
-              columns _col0,_col1,_col3,_col4,_col5,_col7
-              columns.types int,string,string,int,string,string
+              columns _col0,_col1,_col2,_col3,_col4,_col5,_col6,_col7
+              columns.types int,string,string,string,int,string,string,string
               escape.delim \
               serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
             serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
@@ -772,8 +780,8 @@ STAGE PLANS:
               input format: org.apache.hadoop.mapred.SequenceFileInputFormat
               output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
               properties:
-                columns _col0,_col1,_col3,_col4,_col5,_col7
-                columns.types int,string,string,int,string,string
+                columns _col0,_col1,_col2,_col3,_col4,_col5,_col6,_col7
+                columns.types int,string,string,string,int,string,string,string
                 escape.delim \
                 serialization.lib org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
               serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
@@ -782,7 +790,7 @@ STAGE PLANS:
       Needs Tagging: false
       Reduce Operator Tree:
         Select Operator
-          expressions: KEY.reducesinkkey0 (type: int), VALUE._col0 (type: string), '2000-04-08' (type: string), VALUE._col2 (type: string), VALUE._col3 (type: int), VALUE._col4 (type: string), '2000-04-09' (type: string), VALUE._col6 (type: string)
+          expressions: KEY.reducesinkkey0 (type: int), VALUE._col0 (type: string), VALUE._col1 (type: string), VALUE._col2 (type: string), VALUE._col3 (type: int), VALUE._col4 (type: string), VALUE._col5 (type: string), VALUE._col6 (type: string)
           outputColumnNames: _col0, _col1, _col2, _col3, _col4, _col5, _col6, _col7
           Statistics: Num rows: 22 Data size: 176 Basic stats: COMPLETE Column stats: NONE
           File Output Operator
@@ -814,7 +822,7 @@ STAGE PLANS:
       Processor Tree:
         ListSink
 
-Warning: Shuffle Join JOIN[9][tables = [$hdt$_0, $hdt$_1]] in Stage 'Stage-1:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[8][tables = [$hdt$_0, $hdt$_1]] in Stage 'Stage-1:MAPRED' is a cross product
 PREHOOK: query: explain extended
 select *
 from pcr_t1 t1 join pcr_t1 t2

http://git-wip-us.apache.org/repos/asf/hive/blob/10423f51/ql/src/test/results/clientpositive/ppd_constant_expr.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/ppd_constant_expr.q.out b/ql/src/test/results/clientpositive/ppd_constant_expr.q.out
index 17e2bab..21ea071 100644
--- a/ql/src/test/results/clientpositive/ppd_constant_expr.q.out
+++ b/ql/src/test/results/clientpositive/ppd_constant_expr.q.out
@@ -106,9 +106,9 @@ INSERT OVERWRITE TABLE ppd_constant_expr SELECT 4 + NULL, src1.key - NULL, NULL
 POSTHOOK: type: QUERY
 POSTHOOK: Input: default@src1
 POSTHOOK: Output: default@ppd_constant_expr
-POSTHOOK: Lineage: ppd_constant_expr.c1 EXPRESSION []
+POSTHOOK: Lineage: ppd_constant_expr.c1 SIMPLE []
 POSTHOOK: Lineage: ppd_constant_expr.c2 EXPRESSION [(src1)src1.FieldSchema(name:key, type:string, comment:default), ]
-POSTHOOK: Lineage: ppd_constant_expr.c3 EXPRESSION []
+POSTHOOK: Lineage: ppd_constant_expr.c3 SIMPLE []
 PREHOOK: query: SELECT ppd_constant_expr.* FROM ppd_constant_expr
 PREHOOK: type: QUERY
 PREHOOK: Input: default@ppd_constant_expr
@@ -242,9 +242,9 @@ INSERT OVERWRITE TABLE ppd_constant_expr SELECT 4 + NULL, src1.key - NULL, NULL
 POSTHOOK: type: QUERY
 POSTHOOK: Input: default@src1
 POSTHOOK: Output: default@ppd_constant_expr
-POSTHOOK: Lineage: ppd_constant_expr.c1 EXPRESSION []
+POSTHOOK: Lineage: ppd_constant_expr.c1 SIMPLE []
 POSTHOOK: Lineage: ppd_constant_expr.c2 EXPRESSION [(src1)src1.FieldSchema(name:key, type:string, comment:default), ]
-POSTHOOK: Lineage: ppd_constant_expr.c3 EXPRESSION []
+POSTHOOK: Lineage: ppd_constant_expr.c3 SIMPLE []
 PREHOOK: query: SELECT ppd_constant_expr.* FROM ppd_constant_expr
 PREHOOK: type: QUERY
 PREHOOK: Input: default@ppd_constant_expr

http://git-wip-us.apache.org/repos/asf/hive/blob/10423f51/ql/src/test/results/clientpositive/ppd_join5.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/ppd_join5.q.out b/ql/src/test/results/clientpositive/ppd_join5.q.out
index f464c17..44607a0 100644
--- a/ql/src/test/results/clientpositive/ppd_join5.q.out
+++ b/ql/src/test/results/clientpositive/ppd_join5.q.out
@@ -32,7 +32,7 @@ POSTHOOK: Lineage: t1.id1 SIMPLE []
 POSTHOOK: Lineage: t1.id2 SIMPLE []
 POSTHOOK: Lineage: t2.d SIMPLE []
 POSTHOOK: Lineage: t2.id SIMPLE []
-Warning: Shuffle Join JOIN[15][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-2:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[14][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-2:MAPRED' is a cross product
 PREHOOK: query: explain
 select a.*,b.d d1,c.d d2 from
   t1 a join t2 b on (a.id1 = b.id)
@@ -148,7 +148,7 @@ STAGE PLANS:
       Processor Tree:
         ListSink
 
-Warning: Shuffle Join JOIN[15][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-2:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[14][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-2:MAPRED' is a cross product
 PREHOOK: query: explain
 select * from (
 select a.*,b.d d1,c.d d2 from
@@ -271,7 +271,7 @@ STAGE PLANS:
       Processor Tree:
         ListSink
 
-Warning: Shuffle Join JOIN[15][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-2:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[14][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-2:MAPRED' is a cross product
 PREHOOK: query: select * from (
 select a.*,b.d d1,c.d d2 from
   t1 a join t2 b on (a.id1 = b.id)

http://git-wip-us.apache.org/repos/asf/hive/blob/10423f51/ql/src/test/results/clientpositive/ppd_outer_join4.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/ppd_outer_join4.q.out b/ql/src/test/results/clientpositive/ppd_outer_join4.q.out
index ba5d187..ea0772a 100644
--- a/ql/src/test/results/clientpositive/ppd_outer_join4.q.out
+++ b/ql/src/test/results/clientpositive/ppd_outer_join4.q.out
@@ -38,33 +38,33 @@ STAGE PLANS:
             alias: a
             Statistics: Num rows: 500 Data size: 5312 Basic stats: COMPLETE Column stats: NONE
             Filter Operator
-              predicate: ((sqrt(key) <> 13.0) and (key > '10') and (key < '20') and (key > '15') and (key < '25')) (type: boolean)
+              predicate: ((key > '10') and (key < '20') and (key > '15') and (key < '25') and (sqrt(key) <> 13.0)) (type: boolean)
               Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
               Select Operator
-                expressions: key (type: string)
-                outputColumnNames: _col0
+                expressions: key (type: string), value (type: string)
+                outputColumnNames: _col0, _col1
                 Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
                 Reduce Output Operator
                   key expressions: _col0 (type: string)
                   sort order: +
                   Map-reduce partition columns: _col0 (type: string)
                   Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
+                  value expressions: _col1 (type: string)
           TableScan
             alias: a
             Statistics: Num rows: 500 Data size: 5312 Basic stats: COMPLETE Column stats: NONE
             Filter Operator
-              predicate: ((key > '10') and (key < '20') and (key > '15') and (key < '25') and (sqrt(key) <> 13.0)) (type: boolean)
+              predicate: ((sqrt(key) <> 13.0) and (key > '10') and (key < '20') and (key > '15') and (key < '25')) (type: boolean)
               Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
               Select Operator
-                expressions: key (type: string), value (type: string)
-                outputColumnNames: _col0, _col1
+                expressions: key (type: string)
+                outputColumnNames: _col0
                 Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
                 Reduce Output Operator
                   key expressions: _col0 (type: string)
                   sort order: +
                   Map-reduce partition columns: _col0 (type: string)
                   Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
-                  value expressions: _col1 (type: string)
           TableScan
             alias: a
             Statistics: Num rows: 500 Data size: 5312 Basic stats: COMPLETE Column stats: NONE
@@ -85,7 +85,7 @@ STAGE PLANS:
         Join Operator
           condition map:
                Inner Join 0 to 1
-               Inner Join 1 to 2
+               Inner Join 0 to 2
           keys:
             0 _col0 (type: string)
             1 _col0 (type: string)
@@ -93,7 +93,7 @@ STAGE PLANS:
           outputColumnNames: _col0, _col1, _col2, _col3, _col4
           Statistics: Num rows: 13 Data size: 138 Basic stats: COMPLETE Column stats: NONE
           Select Operator
-            expressions: _col1 (type: string), _col2 (type: string), _col3 (type: string), _col4 (type: string), _col0 (type: string)
+            expressions: _col0 (type: string), _col1 (type: string), _col3 (type: string), _col4 (type: string), _col2 (type: string)
             outputColumnNames: _col0, _col1, _col2, _col3, _col4
             Statistics: Num rows: 13 Data size: 138 Basic stats: COMPLETE Column stats: NONE
             File Output Operator
@@ -402,33 +402,33 @@ STAGE PLANS:
             alias: a
             Statistics: Num rows: 500 Data size: 5312 Basic stats: COMPLETE Column stats: NONE
             Filter Operator
-              predicate: ((sqrt(key) <> 13.0) and (key > '10') and (key < '20') and (key > '15') and (key < '25')) (type: boolean)
+              predicate: ((key > '10') and (key < '20') and (key > '15') and (key < '25') and (sqrt(key) <> 13.0)) (type: boolean)
               Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
               Select Operator
-                expressions: key (type: string)
-                outputColumnNames: _col0
+                expressions: key (type: string), value (type: string)
+                outputColumnNames: _col0, _col1
                 Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
                 Reduce Output Operator
                   key expressions: _col0 (type: string)
                   sort order: +
                   Map-reduce partition columns: _col0 (type: string)
                   Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
+                  value expressions: _col1 (type: string)
           TableScan
             alias: a
             Statistics: Num rows: 500 Data size: 5312 Basic stats: COMPLETE Column stats: NONE
             Filter Operator
-              predicate: ((key > '10') and (key < '20') and (key > '15') and (key < '25') and (sqrt(key) <> 13.0)) (type: boolean)
+              predicate: ((sqrt(key) <> 13.0) and (key > '10') and (key < '20') and (key > '15') and (key < '25')) (type: boolean)
               Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
               Select Operator
-                expressions: key (type: string), value (type: string)
-                outputColumnNames: _col0, _col1
+                expressions: key (type: string)
+                outputColumnNames: _col0
                 Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
                 Reduce Output Operator
                   key expressions: _col0 (type: string)
                   sort order: +
                   Map-reduce partition columns: _col0 (type: string)
                   Statistics: Num rows: 6 Data size: 63 Basic stats: COMPLETE Column stats: NONE
-                  value expressions: _col1 (type: string)
           TableScan
             alias: a
             Statistics: Num rows: 500 Data size: 5312 Basic stats: COMPLETE Column stats: NONE
@@ -449,7 +449,7 @@ STAGE PLANS:
         Join Operator
           condition map:
                Inner Join 0 to 1
-               Inner Join 1 to 2
+               Inner Join 0 to 2
           keys:
             0 _col0 (type: string)
             1 _col0 (type: string)
@@ -457,7 +457,7 @@ STAGE PLANS:
           outputColumnNames: _col0, _col1, _col2, _col3, _col4
           Statistics: Num rows: 13 Data size: 138 Basic stats: COMPLETE Column stats: NONE
           Select Operator
-            expressions: _col1 (type: string), _col2 (type: string), _col3 (type: string), _col4 (type: string), _col0 (type: string)
+            expressions: _col0 (type: string), _col1 (type: string), _col3 (type: string), _col4 (type: string), _col2 (type: string)
             outputColumnNames: _col0, _col1, _col2, _col3, _col4
             Statistics: Num rows: 13 Data size: 138 Basic stats: COMPLETE Column stats: NONE
             File Output Operator

http://git-wip-us.apache.org/repos/asf/hive/blob/10423f51/ql/src/test/results/clientpositive/ppd_outer_join5.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/ppd_outer_join5.q.out b/ql/src/test/results/clientpositive/ppd_outer_join5.q.out
index 65ca9d1..643a589 100644
--- a/ql/src/test/results/clientpositive/ppd_outer_join5.q.out
+++ b/ql/src/test/results/clientpositive/ppd_outer_join5.q.out
@@ -30,7 +30,7 @@ POSTHOOK: query: create table t4 (id int, key string, value string)
 POSTHOOK: type: CREATETABLE
 POSTHOOK: Output: database:default
 POSTHOOK: Output: default@t4
-Warning: Shuffle Join JOIN[13][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-1:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[12][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-1:MAPRED' is a cross product
 PREHOOK: query: explain select * from t1 full outer join t2 on t1.id=t2.id join t3 on t2.id=t3.id where t3.id=20
 PREHOOK: type: QUERY
 POSTHOOK: query: explain select * from t1 full outer join t2 on t1.id=t2.id join t3 on t2.id=t3.id where t3.id=20
@@ -118,7 +118,7 @@ STAGE PLANS:
       Processor Tree:
         ListSink
 
-Warning: Shuffle Join JOIN[14][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-1:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[12][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-1:MAPRED' is a cross product
 PREHOOK: query: explain select * from t1 join t2 on (t1.id=t2.id) left outer join t3 on (t2.id=t3.id) where t2.id=20
 PREHOOK: type: QUERY
 POSTHOOK: query: explain select * from t1 join t2 on (t1.id=t2.id) left outer join t3 on (t2.id=t3.id) where t2.id=20
@@ -202,7 +202,7 @@ STAGE PLANS:
       Processor Tree:
         ListSink
 
-Warning: Shuffle Join JOIN[14][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-1:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[12][tables = [$hdt$_0, $hdt$_1, $hdt$_2]] in Stage 'Stage-1:MAPRED' is a cross product
 PREHOOK: query: explain select * from t1 join t2 on (t1.id=t2.id) left outer join t3 on (t1.id=t3.id) where t2.id=20
 PREHOOK: type: QUERY
 POSTHOOK: query: explain select * from t1 join t2 on (t1.id=t2.id) left outer join t3 on (t1.id=t3.id) where t2.id=20

http://git-wip-us.apache.org/repos/asf/hive/blob/10423f51/ql/src/test/results/clientpositive/ppd_repeated_alias.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/ppd_repeated_alias.q.out b/ql/src/test/results/clientpositive/ppd_repeated_alias.q.out
index 3dbd258..a50e10c 100644
--- a/ql/src/test/results/clientpositive/ppd_repeated_alias.q.out
+++ b/ql/src/test/results/clientpositive/ppd_repeated_alias.q.out
@@ -263,7 +263,7 @@ STAGE PLANS:
       Processor Tree:
         ListSink
 
-Warning: Shuffle Join JOIN[16][tables = [$hdt$_0, $hdt$_1]] in Stage 'Stage-2:MAPRED' is a cross product
+Warning: Shuffle Join JOIN[15][tables = [$hdt$_0, $hdt$_1]] in Stage 'Stage-2:MAPRED' is a cross product
 PREHOOK: query: -- Q4: here, the filter c.bar should be created under the first join but above the second
 explain select c.foo, d.bar from (select c.foo, b.bar, c.blah from pokes c left outer join pokes b on c.foo=b.foo) c left outer join pokes d where d.foo=1 and c.bar=2
 PREHOOK: type: QUERY