http://git-wip-us.apache.org/repos/asf/hive/blob/55887646/ql/src/test/results/clientpositive/llap/dynamic_partition_pruning.q.out
----------------------------------------------------------------------
diff --git 
a/ql/src/test/results/clientpositive/llap/dynamic_partition_pruning.q.out 
b/ql/src/test/results/clientpositive/llap/dynamic_partition_pruning.q.out
index accb3a7..6954647 100644
--- a/ql/src/test/results/clientpositive/llap/dynamic_partition_pruning.q.out
+++ b/ql/src/test/results/clientpositive/llap/dynamic_partition_pruning.q.out
@@ -535,14 +535,14 @@ STAGE PLANS:
                   filterExpr: ds is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: ds (type: string)
+                    expressions: day(CAST( ds AS DATE)) (type: int)
                     outputColumnNames: _col0
-                    Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 8000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Reduce Output Operator
-                      key expressions: day(CAST( _col0 AS DATE)) (type: int)
+                      key expressions: _col0 (type: int)
                       sort order: +
-                      Map-reduce partition columns: day(CAST( _col0 AS DATE)) 
(type: int)
-                      Statistics: Num rows: 2000 Data size: 368000 Basic 
stats: COMPLETE Column stats: COMPLETE
+                      Map-reduce partition columns: _col0 (type: int)
+                      Statistics: Num rows: 2000 Data size: 8000 Basic stats: 
COMPLETE Column stats: COMPLETE
             Execution mode: llap
             LLAP IO: no inputs
         Map 4 
@@ -555,16 +555,16 @@ STAGE PLANS:
                     predicate: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
                     Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: ds (type: string)
+                      expressions: day(CAST( ds AS DATE)) (type: int)
                       outputColumnNames: _col0
                       Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: day(CAST( _col0 AS DATE)) (type: int)
+                        key expressions: _col0 (type: int)
                         sort order: +
-                        Map-reduce partition columns: day(CAST( _col0 AS 
DATE)) (type: int)
+                        Map-reduce partition columns: _col0 (type: int)
                         Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                       Select Operator
-                        expressions: day(CAST( _col0 AS DATE)) (type: int)
+                        expressions: _col0 (type: int)
                         outputColumnNames: _col0
                         Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                         Group By Operator
@@ -587,9 +587,9 @@ STAGE PLANS:
                 condition map:
                      Inner Join 0 to 1
                 keys:
-                  0 day(CAST( _col0 AS DATE)) (type: int)
-                  1 day(CAST( _col0 AS DATE)) (type: int)
-                Statistics: Num rows: 2200 Data size: 404800 Basic stats: 
COMPLETE Column stats: NONE
+                  0 _col0 (type: int)
+                  1 _col0 (type: int)
+                Statistics: Num rows: 2200 Data size: 8800 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
                   mode: hash
@@ -678,14 +678,14 @@ STAGE PLANS:
                   filterExpr: ds is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: ds (type: string)
+                    expressions: day(CAST( ds AS DATE)) (type: int)
                     outputColumnNames: _col0
-                    Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 8000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Reduce Output Operator
-                      key expressions: day(CAST( _col0 AS DATE)) (type: int)
+                      key expressions: _col0 (type: int)
                       sort order: +
-                      Map-reduce partition columns: day(CAST( _col0 AS DATE)) 
(type: int)
-                      Statistics: Num rows: 2000 Data size: 368000 Basic 
stats: COMPLETE Column stats: COMPLETE
+                      Map-reduce partition columns: _col0 (type: int)
+                      Statistics: Num rows: 2000 Data size: 8000 Basic stats: 
COMPLETE Column stats: COMPLETE
             Execution mode: llap
             LLAP IO: no inputs
         Map 4 
@@ -698,13 +698,13 @@ STAGE PLANS:
                     predicate: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
                     Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: ds (type: string)
+                      expressions: day(CAST( ds AS DATE)) (type: int)
                       outputColumnNames: _col0
                       Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: day(CAST( _col0 AS DATE)) (type: int)
+                        key expressions: _col0 (type: int)
                         sort order: +
-                        Map-reduce partition columns: day(CAST( _col0 AS 
DATE)) (type: int)
+                        Map-reduce partition columns: _col0 (type: int)
                         Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
             Execution mode: llap
             LLAP IO: no inputs
@@ -715,9 +715,9 @@ STAGE PLANS:
                 condition map:
                      Inner Join 0 to 1
                 keys:
-                  0 day(CAST( _col0 AS DATE)) (type: int)
-                  1 day(CAST( _col0 AS DATE)) (type: int)
-                Statistics: Num rows: 2200 Data size: 404800 Basic stats: 
COMPLETE Column stats: NONE
+                  0 _col0 (type: int)
+                  1 _col0 (type: int)
+                Statistics: Num rows: 2200 Data size: 8800 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
                   mode: hash
@@ -1214,12 +1214,12 @@ STAGE PLANS:
                     Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
                       expressions: ds (type: string), hr (type: string)
-                      outputColumnNames: _col0, _col2
+                      outputColumnNames: _col0, _col1
                       Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: _col0 (type: string), _col2 (type: 
string)
+                        key expressions: _col0 (type: string), _col1 (type: 
string)
                         sort order: ++
-                        Map-reduce partition columns: _col0 (type: string), 
_col2 (type: string)
+                        Map-reduce partition columns: _col0 (type: string), 
_col1 (type: string)
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Select Operator
                         expressions: _col0 (type: string)
@@ -1237,7 +1237,7 @@ STAGE PLANS:
                             Statistics: Num rows: 2 Data size: 1472 Basic 
stats: COMPLETE Column stats: NONE
                             Target Vertex: Map 1
                       Select Operator
-                        expressions: _col2 (type: string)
+                        expressions: _col1 (type: string)
                         outputColumnNames: _col0
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                         Group By Operator
@@ -1261,7 +1261,7 @@ STAGE PLANS:
                      Inner Join 0 to 1
                 keys:
                   0 _col0 (type: string), _col1 (type: string)
-                  1 _col0 (type: string), _col2 (type: string)
+                  1 _col0 (type: string), _col1 (type: string)
                 Statistics: Num rows: 2200 Data size: 809600 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
@@ -1372,12 +1372,12 @@ STAGE PLANS:
                     Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
                       expressions: ds (type: string), hr (type: string)
-                      outputColumnNames: _col0, _col2
+                      outputColumnNames: _col0, _col1
                       Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: _col0 (type: string), _col2 (type: 
string)
+                        key expressions: _col0 (type: string), _col1 (type: 
string)
                         sort order: ++
-                        Map-reduce partition columns: _col0 (type: string), 
_col2 (type: string)
+                        Map-reduce partition columns: _col0 (type: string), 
_col1 (type: string)
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
             Execution mode: llap
             LLAP IO: no inputs
@@ -1389,7 +1389,7 @@ STAGE PLANS:
                      Inner Join 0 to 1
                 keys:
                   0 _col0 (type: string), _col1 (type: string)
-                  1 _col0 (type: string), _col2 (type: string)
+                  1 _col0 (type: string), _col1 (type: string)
                 Statistics: Num rows: 2200 Data size: 809600 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
@@ -1770,14 +1770,14 @@ STAGE PLANS:
                   filterExpr: hr is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: hr (type: string)
+                    expressions: UDFToDouble(hr) (type: double)
                     outputColumnNames: _col0
-                    Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Reduce Output Operator
-                      key expressions: UDFToDouble(_col0) (type: double)
+                      key expressions: _col0 (type: double)
                       sort order: +
-                      Map-reduce partition columns: UDFToDouble(_col0) (type: 
double)
-                      Statistics: Num rows: 2000 Data size: 368000 Basic 
stats: COMPLETE Column stats: COMPLETE
+                      Map-reduce partition columns: _col0 (type: double)
+                      Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
             Execution mode: llap
             LLAP IO: no inputs
         Map 4 
@@ -1790,16 +1790,16 @@ STAGE PLANS:
                     predicate: ((UDFToDouble(hour) = 11.0D) and hr is not 
null) (type: boolean)
                     Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: hr (type: double)
+                      expressions: UDFToDouble(UDFToInteger((hr / 2.0D))) 
(type: double)
                       outputColumnNames: _col0
                       Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: UDFToDouble(UDFToInteger((_col0 / 
2.0D))) (type: double)
+                        key expressions: _col0 (type: double)
                         sort order: +
-                        Map-reduce partition columns: 
UDFToDouble(UDFToInteger((_col0 / 2.0D))) (type: double)
+                        Map-reduce partition columns: _col0 (type: double)
                         Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                       Select Operator
-                        expressions: UDFToDouble(UDFToInteger((_col0 / 2.0D))) 
(type: double)
+                        expressions: _col0 (type: double)
                         outputColumnNames: _col0
                         Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                         Group By Operator
@@ -1822,9 +1822,9 @@ STAGE PLANS:
                 condition map:
                      Inner Join 0 to 1
                 keys:
-                  0 UDFToDouble(_col0) (type: double)
-                  1 UDFToDouble(UDFToInteger((_col0 / 2.0D))) (type: double)
-                Statistics: Num rows: 2200 Data size: 404800 Basic stats: 
COMPLETE Column stats: NONE
+                  0 _col0 (type: double)
+                  1 _col0 (type: double)
+                Statistics: Num rows: 2200 Data size: 17600 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
                   mode: hash
@@ -1913,14 +1913,14 @@ STAGE PLANS:
                   filterExpr: hr is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: hr (type: string)
+                    expressions: (UDFToDouble(hr) * 2.0D) (type: double)
                     outputColumnNames: _col0
-                    Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Reduce Output Operator
-                      key expressions: (UDFToDouble(_col0) * 2.0D) (type: 
double)
+                      key expressions: _col0 (type: double)
                       sort order: +
-                      Map-reduce partition columns: (UDFToDouble(_col0) * 
2.0D) (type: double)
-                      Statistics: Num rows: 2000 Data size: 368000 Basic 
stats: COMPLETE Column stats: COMPLETE
+                      Map-reduce partition columns: _col0 (type: double)
+                      Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
             Execution mode: llap
             LLAP IO: no inputs
         Map 4 
@@ -1965,9 +1965,9 @@ STAGE PLANS:
                 condition map:
                      Inner Join 0 to 1
                 keys:
-                  0 (UDFToDouble(_col0) * 2.0D) (type: double)
+                  0 _col0 (type: double)
                   1 _col0 (type: double)
-                Statistics: Num rows: 2200 Data size: 404800 Basic stats: 
COMPLETE Column stats: NONE
+                Statistics: Num rows: 2200 Data size: 17600 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
                   mode: hash
@@ -2056,14 +2056,14 @@ STAGE PLANS:
                   filterExpr: hr is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: hr (type: string)
+                    expressions: UDFToDouble(hr) (type: double)
                     outputColumnNames: _col0
-                    Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Reduce Output Operator
-                      key expressions: UDFToDouble(_col0) (type: double)
+                      key expressions: _col0 (type: double)
                       sort order: +
-                      Map-reduce partition columns: UDFToDouble(_col0) (type: 
double)
-                      Statistics: Num rows: 2000 Data size: 368000 Basic 
stats: COMPLETE Column stats: COMPLETE
+                      Map-reduce partition columns: _col0 (type: double)
+                      Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
             Execution mode: llap
             LLAP IO: no inputs
         Map 4 
@@ -2076,13 +2076,13 @@ STAGE PLANS:
                     predicate: ((UDFToDouble(hour) = 11.0D) and hr is not 
null) (type: boolean)
                     Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: hr (type: double)
+                      expressions: UDFToDouble(UDFToInteger((hr / 2.0D))) 
(type: double)
                       outputColumnNames: _col0
                       Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: UDFToDouble(UDFToInteger((_col0 / 
2.0D))) (type: double)
+                        key expressions: _col0 (type: double)
                         sort order: +
-                        Map-reduce partition columns: 
UDFToDouble(UDFToInteger((_col0 / 2.0D))) (type: double)
+                        Map-reduce partition columns: _col0 (type: double)
                         Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
             Execution mode: llap
             LLAP IO: no inputs
@@ -2093,9 +2093,9 @@ STAGE PLANS:
                 condition map:
                      Inner Join 0 to 1
                 keys:
-                  0 UDFToDouble(_col0) (type: double)
-                  1 UDFToDouble(UDFToInteger((_col0 / 2.0D))) (type: double)
-                Statistics: Num rows: 2200 Data size: 404800 Basic stats: 
COMPLETE Column stats: NONE
+                  0 _col0 (type: double)
+                  1 _col0 (type: double)
+                Statistics: Num rows: 2200 Data size: 17600 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
                   mode: hash
@@ -2184,14 +2184,14 @@ STAGE PLANS:
                   filterExpr: hr is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: hr (type: string)
+                    expressions: (UDFToDouble(hr) * 2.0D) (type: double)
                     outputColumnNames: _col0
-                    Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Reduce Output Operator
-                      key expressions: (UDFToDouble(_col0) * 2.0D) (type: 
double)
+                      key expressions: _col0 (type: double)
                       sort order: +
-                      Map-reduce partition columns: (UDFToDouble(_col0) * 
2.0D) (type: double)
-                      Statistics: Num rows: 2000 Data size: 368000 Basic 
stats: COMPLETE Column stats: COMPLETE
+                      Map-reduce partition columns: _col0 (type: double)
+                      Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
             Execution mode: llap
             LLAP IO: no inputs
         Map 4 
@@ -2221,9 +2221,9 @@ STAGE PLANS:
                 condition map:
                      Inner Join 0 to 1
                 keys:
-                  0 (UDFToDouble(_col0) * 2.0D) (type: double)
+                  0 _col0 (type: double)
                   1 _col0 (type: double)
-                Statistics: Num rows: 2200 Data size: 404800 Basic stats: 
COMPLETE Column stats: NONE
+                Statistics: Num rows: 2200 Data size: 17600 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
                   mode: hash
@@ -2325,13 +2325,13 @@ STAGE PLANS:
                   filterExpr: hr is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: hr (type: string)
+                    expressions: CAST( (UDFToDouble(hr) * 2.0D) AS STRING) 
(type: string)
                     outputColumnNames: _col0
                     Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Reduce Output Operator
-                      key expressions: CAST( (UDFToDouble(_col0) * 2.0D) AS 
STRING) (type: string)
+                      key expressions: _col0 (type: string)
                       sort order: +
-                      Map-reduce partition columns: CAST( (UDFToDouble(_col0) 
* 2.0D) AS STRING) (type: string)
+                      Map-reduce partition columns: _col0 (type: string)
                       Statistics: Num rows: 2000 Data size: 368000 Basic 
stats: COMPLETE Column stats: COMPLETE
             Execution mode: llap
             LLAP IO: no inputs
@@ -2345,16 +2345,16 @@ STAGE PLANS:
                     predicate: ((UDFToDouble(hour) = 11.0D) and hr is not 
null) (type: boolean)
                     Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: hr (type: double)
+                      expressions: CAST( hr AS STRING) (type: string)
                       outputColumnNames: _col0
                       Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: CAST( _col0 AS STRING) (type: string)
+                        key expressions: _col0 (type: string)
                         sort order: +
-                        Map-reduce partition columns: CAST( _col0 AS STRING) 
(type: string)
+                        Map-reduce partition columns: _col0 (type: string)
                         Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                       Select Operator
-                        expressions: CAST( _col0 AS STRING) (type: string)
+                        expressions: _col0 (type: string)
                         outputColumnNames: _col0
                         Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                         Group By Operator
@@ -2377,8 +2377,8 @@ STAGE PLANS:
                 condition map:
                      Inner Join 0 to 1
                 keys:
-                  0 CAST( (UDFToDouble(_col0) * 2.0D) AS STRING) (type: string)
-                  1 CAST( _col0 AS STRING) (type: string)
+                  0 _col0 (type: string)
+                  1 _col0 (type: string)
                 Statistics: Num rows: 2200 Data size: 404800 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
@@ -2632,12 +2632,12 @@ STAGE PLANS:
                     Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
                       expressions: ds (type: string), hr (type: string)
-                      outputColumnNames: _col0, _col2
+                      outputColumnNames: _col0, _col1
                       Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
                         sort order: 
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
-                        value expressions: _col0 (type: string), _col2 (type: 
string)
+                        value expressions: _col0 (type: string), _col1 (type: 
string)
             Execution mode: llap
             LLAP IO: no inputs
         Reducer 2 
@@ -2649,8 +2649,8 @@ STAGE PLANS:
                 keys:
                   0 
                   1 
-                outputColumnNames: _col0, _col1, _col2, _col4
-                residual filter predicates: {((_col0 = _col2) or (_col1 = 
_col4))}
+                outputColumnNames: _col0, _col1, _col2, _col3
+                residual filter predicates: {((_col0 = _col2) or (_col1 = 
_col3))}
                 Statistics: Num rows: 4000 Data size: 4420000 Basic stats: 
COMPLETE Column stats: NONE
                 Select Operator
                   Statistics: Num rows: 4000 Data size: 4420000 Basic stats: 
COMPLETE Column stats: NONE
@@ -2763,12 +2763,12 @@ STAGE PLANS:
                     Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
                       expressions: ds (type: string), hr (type: string)
-                      outputColumnNames: _col0, _col2
+                      outputColumnNames: _col0, _col1
                       Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: _col0 (type: string), _col2 (type: 
string)
+                        key expressions: _col0 (type: string), _col1 (type: 
string)
                         sort order: ++
-                        Map-reduce partition columns: _col0 (type: string), 
_col2 (type: string)
+                        Map-reduce partition columns: _col0 (type: string), 
_col1 (type: string)
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Select Operator
                         expressions: _col0 (type: string)
@@ -2786,7 +2786,7 @@ STAGE PLANS:
                             Statistics: Num rows: 2 Data size: 1472 Basic 
stats: COMPLETE Column stats: NONE
                             Target Vertex: Map 1
                       Select Operator
-                        expressions: _col2 (type: string)
+                        expressions: _col1 (type: string)
                         outputColumnNames: _col0
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                         Group By Operator
@@ -2810,7 +2810,7 @@ STAGE PLANS:
                      Inner Join 0 to 1
                 keys:
                   0 _col0 (type: string), _col1 (type: string)
-                  1 _col0 (type: string), _col2 (type: string)
+                  1 _col0 (type: string), _col1 (type: string)
                 Statistics: Num rows: 2200 Data size: 809600 Basic stats: 
COMPLETE Column stats: NONE
                 Group By Operator
                   aggregations: count()
@@ -3458,21 +3458,21 @@ STAGE PLANS:
         Map 1 
             Map Operator Tree:
                 TableScan
-                  alias: srcpart_hour_n0
-                  filterExpr: (UDFToDouble(hr) = 13.0D) (type: boolean)
-                  Statistics: Num rows: 2 Data size: 368 Basic stats: COMPLETE 
Column stats: NONE
+                  alias: srcpart_date_n2
+                  filterExpr: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
+                  Statistics: Num rows: 2 Data size: 736 Basic stats: COMPLETE 
Column stats: NONE
                   Filter Operator
-                    predicate: (UDFToDouble(hr) = 13.0D) (type: boolean)
-                    Statistics: Num rows: 1 Data size: 184 Basic stats: 
COMPLETE Column stats: NONE
+                    predicate: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
+                    Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: hr (type: string)
+                      expressions: ds (type: string)
                       outputColumnNames: _col0
-                      Statistics: Num rows: 1 Data size: 184 Basic stats: 
COMPLETE Column stats: NONE
+                      Statistics: Num rows: 2 Data size: 736 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: 1 Data size: 184 Basic stats: 
COMPLETE Column stats: NONE
+                        Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
             Execution mode: llap
             LLAP IO: no inputs
         Map 5 
@@ -3489,31 +3489,31 @@ STAGE PLANS:
                       outputColumnNames: _col0, _col1
                       Statistics: Num rows: 1 Data size: 368 Basic stats: 
COMPLETE Column stats: COMPLETE
                       Reduce Output Operator
-                        key expressions: _col1 (type: string)
+                        key expressions: _col0 (type: string)
                         sort order: +
-                        Map-reduce partition columns: _col1 (type: string)
+                        Map-reduce partition columns: _col0 (type: string)
                         Statistics: Num rows: 1 Data size: 368 Basic stats: 
COMPLETE Column stats: COMPLETE
-                        value expressions: _col0 (type: string)
+                        value expressions: _col1 (type: string)
             Execution mode: llap
             LLAP IO: unknown
         Map 6 
             Map Operator Tree:
                 TableScan
-                  alias: srcpart_date_n2
-                  filterExpr: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
-                  Statistics: Num rows: 2 Data size: 736 Basic stats: COMPLETE 
Column stats: NONE
+                  alias: srcpart_hour_n0
+                  filterExpr: (UDFToDouble(hr) = 13.0D) (type: boolean)
+                  Statistics: Num rows: 2 Data size: 368 Basic stats: COMPLETE 
Column stats: NONE
                   Filter Operator
-                    predicate: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
-                    Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
+                    predicate: (UDFToDouble(hr) = 13.0D) (type: boolean)
+                    Statistics: Num rows: 1 Data size: 184 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: ds (type: string)
+                      expressions: hr (type: string)
                       outputColumnNames: _col0
-                      Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
+                      Statistics: Num rows: 1 Data size: 184 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: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
+                        Statistics: Num rows: 1 Data size: 184 Basic stats: 
COMPLETE Column stats: NONE
             Execution mode: llap
             LLAP IO: no inputs
         Reducer 2 
@@ -3524,14 +3524,14 @@ STAGE PLANS:
                      Inner Join 0 to 1
                 keys:
                   0 _col0 (type: string)
-                  1 _col1 (type: string)
-                outputColumnNames: _col1
-                Statistics: Num rows: 1 Data size: 202 Basic stats: COMPLETE 
Column stats: NONE
+                  1 _col0 (type: string)
+                outputColumnNames: _col2
+                Statistics: Num rows: 2 Data size: 809 Basic stats: COMPLETE 
Column stats: NONE
                 Reduce Output Operator
-                  key expressions: _col1 (type: string)
+                  key expressions: _col2 (type: string)
                   sort order: +
-                  Map-reduce partition columns: _col1 (type: string)
-                  Statistics: Num rows: 1 Data size: 202 Basic stats: COMPLETE 
Column stats: NONE
+                  Map-reduce partition columns: _col2 (type: string)
+                  Statistics: Num rows: 2 Data size: 809 Basic stats: COMPLETE 
Column stats: NONE
         Reducer 3 
             Execution mode: llap
             Reduce Operator Tree:
@@ -3539,9 +3539,9 @@ STAGE PLANS:
                 condition map:
                      Inner Join 0 to 1
                 keys:
-                  0 _col1 (type: string)
+                  0 _col2 (type: string)
                   1 _col0 (type: string)
-                Statistics: Num rows: 2 Data size: 809 Basic stats: COMPLETE 
Column stats: NONE
+                Statistics: Num rows: 2 Data size: 889 Basic stats: COMPLETE 
Column stats: NONE
                 Group By Operator
                   aggregations: count()
                   mode: hash
@@ -4504,18 +4504,18 @@ STAGE PLANS:
                   filterExpr: ds is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: ds (type: string)
+                    expressions: day(CAST( ds AS DATE)) (type: int)
                     outputColumnNames: _col0
-                    Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 8000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Map Join Operator
                       condition map:
                            Inner Join 0 to 1
                       keys:
-                        0 day(CAST( _col0 AS DATE)) (type: int)
-                        1 day(CAST( _col0 AS DATE)) (type: int)
+                        0 _col0 (type: int)
+                        1 _col0 (type: int)
                       input vertices:
                         1 Map 3
-                      Statistics: Num rows: 2200 Data size: 404800 Basic 
stats: COMPLETE Column stats: NONE
+                      Statistics: Num rows: 2200 Data size: 8800 Basic stats: 
COMPLETE Column stats: NONE
                       Group By Operator
                         aggregations: count()
                         mode: hash
@@ -4537,16 +4537,16 @@ STAGE PLANS:
                     predicate: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
                     Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: ds (type: string)
+                      expressions: day(CAST( ds AS DATE)) (type: int)
                       outputColumnNames: _col0
                       Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: day(CAST( _col0 AS DATE)) (type: int)
+                        key expressions: _col0 (type: int)
                         sort order: +
-                        Map-reduce partition columns: day(CAST( _col0 AS 
DATE)) (type: int)
+                        Map-reduce partition columns: _col0 (type: int)
                         Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                       Select Operator
-                        expressions: day(CAST( _col0 AS DATE)) (type: int)
+                        expressions: _col0 (type: int)
                         outputColumnNames: _col0
                         Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                         Group By Operator
@@ -4848,7 +4848,7 @@ STAGE PLANS:
                            Inner Join 0 to 1
                       keys:
                         0 _col0 (type: string), _col1 (type: string)
-                        1 _col0 (type: string), _col2 (type: string)
+                        1 _col0 (type: string), _col1 (type: string)
                       input vertices:
                         1 Map 3
                       Statistics: Num rows: 2200 Data size: 809600 Basic 
stats: COMPLETE Column stats: NONE
@@ -4874,12 +4874,12 @@ STAGE PLANS:
                     Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
                       expressions: ds (type: string), hr (type: string)
-                      outputColumnNames: _col0, _col2
+                      outputColumnNames: _col0, _col1
                       Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: _col0 (type: string), _col2 (type: 
string)
+                        key expressions: _col0 (type: string), _col1 (type: 
string)
                         sort order: ++
-                        Map-reduce partition columns: _col0 (type: string), 
_col2 (type: string)
+                        Map-reduce partition columns: _col0 (type: string), 
_col1 (type: string)
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Select Operator
                         expressions: _col0 (type: string)
@@ -4897,7 +4897,7 @@ STAGE PLANS:
                             Statistics: Num rows: 2 Data size: 1472 Basic 
stats: COMPLETE Column stats: NONE
                             Target Vertex: Map 1
                       Select Operator
-                        expressions: _col2 (type: string)
+                        expressions: _col1 (type: string)
                         outputColumnNames: _col0
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                         Group By Operator
@@ -5140,18 +5140,18 @@ STAGE PLANS:
                   filterExpr: hr is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: hr (type: string)
+                    expressions: UDFToDouble(hr) (type: double)
                     outputColumnNames: _col0
-                    Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Map Join Operator
                       condition map:
                            Inner Join 0 to 1
                       keys:
-                        0 UDFToDouble(_col0) (type: double)
-                        1 UDFToDouble(UDFToInteger((_col0 / 2.0D))) (type: 
double)
+                        0 _col0 (type: double)
+                        1 _col0 (type: double)
                       input vertices:
                         1 Map 3
-                      Statistics: Num rows: 2200 Data size: 404800 Basic 
stats: COMPLETE Column stats: NONE
+                      Statistics: Num rows: 2200 Data size: 17600 Basic stats: 
COMPLETE Column stats: NONE
                       Group By Operator
                         aggregations: count()
                         mode: hash
@@ -5173,16 +5173,16 @@ STAGE PLANS:
                     predicate: ((UDFToDouble(hour) = 11.0D) and hr is not 
null) (type: boolean)
                     Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: hr (type: double)
+                      expressions: UDFToDouble(UDFToInteger((hr / 2.0D))) 
(type: double)
                       outputColumnNames: _col0
                       Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: UDFToDouble(UDFToInteger((_col0 / 
2.0D))) (type: double)
+                        key expressions: _col0 (type: double)
                         sort order: +
-                        Map-reduce partition columns: 
UDFToDouble(UDFToInteger((_col0 / 2.0D))) (type: double)
+                        Map-reduce partition columns: _col0 (type: double)
                         Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                       Select Operator
-                        expressions: UDFToDouble(UDFToInteger((_col0 / 2.0D))) 
(type: double)
+                        expressions: _col0 (type: double)
                         outputColumnNames: _col0
                         Statistics: Num rows: 1 Data size: 192 Basic stats: 
COMPLETE Column stats: NONE
                         Group By Operator
@@ -5277,18 +5277,18 @@ STAGE PLANS:
                   filterExpr: hr is not null (type: boolean)
                   Statistics: Num rows: 2000 Data size: 389248 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: hr (type: string)
+                    expressions: (UDFToDouble(hr) * 2.0D) (type: double)
                     outputColumnNames: _col0
-                    Statistics: Num rows: 2000 Data size: 368000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 16000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Map Join Operator
                       condition map:
                            Inner Join 0 to 1
                       keys:
-                        0 (UDFToDouble(_col0) * 2.0D) (type: double)
+                        0 _col0 (type: double)
                         1 _col0 (type: double)
                       input vertices:
                         1 Map 3
-                      Statistics: Num rows: 2200 Data size: 404800 Basic 
stats: COMPLETE Column stats: NONE
+                      Statistics: Num rows: 2200 Data size: 17600 Basic stats: 
COMPLETE Column stats: NONE
                       Group By Operator
                         aggregations: count()
                         mode: hash
@@ -6046,42 +6046,54 @@ STAGE PLANS:
     Tez
 #### A masked pattern was here ####
       Edges:
-        Map 1 <- Map 2 (BROADCAST_EDGE)
-        Map 3 <- Map 1 (BROADCAST_EDGE)
-        Reducer 4 <- Map 3 (CUSTOM_SIMPLE_EDGE)
+        Map 1 <- Map 3 (BROADCAST_EDGE), Map 4 (BROADCAST_EDGE)
+        Reducer 2 <- Map 1 (CUSTOM_SIMPLE_EDGE)
 #### A masked pattern was here ####
       Vertices:
         Map 1 
             Map Operator Tree:
                 TableScan
-                  alias: srcpart_hour_n0
-                  filterExpr: (UDFToDouble(hr) = 13.0D) (type: boolean)
-                  Statistics: Num rows: 2 Data size: 368 Basic stats: COMPLETE 
Column stats: NONE
+                  alias: srcpart_date_n2
+                  filterExpr: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
+                  Statistics: Num rows: 2 Data size: 736 Basic stats: COMPLETE 
Column stats: NONE
                   Filter Operator
-                    predicate: (UDFToDouble(hr) = 13.0D) (type: boolean)
-                    Statistics: Num rows: 1 Data size: 184 Basic stats: 
COMPLETE Column stats: NONE
+                    predicate: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
+                    Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: hr (type: string)
+                      expressions: ds (type: string)
                       outputColumnNames: _col0
-                      Statistics: Num rows: 1 Data size: 184 Basic stats: 
COMPLETE Column stats: NONE
+                      Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
                       Map Join Operator
                         condition map:
                              Inner Join 0 to 1
                         keys:
                           0 _col0 (type: string)
-                          1 _col1 (type: string)
-                        outputColumnNames: _col1
+                          1 _col0 (type: string)
+                        outputColumnNames: _col2
                         input vertices:
-                          1 Map 2
-                        Statistics: Num rows: 1 Data size: 202 Basic stats: 
COMPLETE Column stats: NONE
-                        Reduce Output Operator
-                          key expressions: _col1 (type: string)
-                          sort order: +
-                          Map-reduce partition columns: _col1 (type: string)
-                          Statistics: Num rows: 1 Data size: 202 Basic stats: 
COMPLETE Column stats: NONE
+                          1 Map 3
+                        Statistics: Num rows: 2 Data size: 809 Basic stats: 
COMPLETE Column stats: NONE
+                        Map Join Operator
+                          condition map:
+                               Inner Join 0 to 1
+                          keys:
+                            0 _col2 (type: string)
+                            1 _col0 (type: string)
+                          input vertices:
+                            1 Map 4
+                          Statistics: Num rows: 2 Data size: 889 Basic stats: 
COMPLETE Column stats: NONE
+                          Group By Operator
+                            aggregations: count()
+                            mode: hash
+                            outputColumnNames: _col0
+                            Statistics: Num rows: 1 Data size: 8 Basic stats: 
COMPLETE Column stats: NONE
+                            Reduce Output Operator
+                              sort order: 
+                              Statistics: Num rows: 1 Data size: 8 Basic 
stats: COMPLETE Column stats: NONE
+                              value expressions: _col0 (type: bigint)
             Execution mode: llap
             LLAP IO: no inputs
-        Map 2 
+        Map 3 
             Map Operator Tree:
                 TableScan
                   alias: srcpart
@@ -6095,47 +6107,34 @@ STAGE PLANS:
                       outputColumnNames: _col0, _col1
                       Statistics: Num rows: 1 Data size: 368 Basic stats: 
COMPLETE Column stats: COMPLETE
                       Reduce Output Operator
-                        key expressions: _col1 (type: string)
+                        key expressions: _col0 (type: string)
                         sort order: +
-                        Map-reduce partition columns: _col1 (type: string)
+                        Map-reduce partition columns: _col0 (type: string)
                         Statistics: Num rows: 1 Data size: 368 Basic stats: 
COMPLETE Column stats: COMPLETE
-                        value expressions: _col0 (type: string)
+                        value expressions: _col1 (type: string)
             Execution mode: llap
             LLAP IO: unknown
-        Map 3 
+        Map 4 
             Map Operator Tree:
                 TableScan
-                  alias: srcpart_date_n2
-                  filterExpr: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
-                  Statistics: Num rows: 2 Data size: 736 Basic stats: COMPLETE 
Column stats: NONE
+                  alias: srcpart_hour_n0
+                  filterExpr: (UDFToDouble(hr) = 13.0D) (type: boolean)
+                  Statistics: Num rows: 2 Data size: 368 Basic stats: COMPLETE 
Column stats: NONE
                   Filter Operator
-                    predicate: ((date = '2008-04-08') and ds is not null) 
(type: boolean)
-                    Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
+                    predicate: (UDFToDouble(hr) = 13.0D) (type: boolean)
+                    Statistics: Num rows: 1 Data size: 184 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: ds (type: string)
+                      expressions: hr (type: string)
                       outputColumnNames: _col0
-                      Statistics: Num rows: 2 Data size: 736 Basic stats: 
COMPLETE Column stats: NONE
-                      Map Join Operator
-                        condition map:
-                             Inner Join 0 to 1
-                        keys:
-                          0 _col1 (type: string)
-                          1 _col0 (type: string)
-                        input vertices:
-                          0 Map 1
-                        Statistics: Num rows: 2 Data size: 809 Basic stats: 
COMPLETE Column stats: NONE
-                        Group By Operator
-                          aggregations: count()
-                          mode: hash
-                          outputColumnNames: _col0
-                          Statistics: Num rows: 1 Data size: 8 Basic stats: 
COMPLETE Column stats: NONE
-                          Reduce Output Operator
-                            sort order: 
-                            Statistics: Num rows: 1 Data size: 8 Basic stats: 
COMPLETE Column stats: NONE
-                            value expressions: _col0 (type: bigint)
+                      Statistics: Num rows: 1 Data size: 184 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: 1 Data size: 184 Basic stats: 
COMPLETE Column stats: NONE
             Execution mode: llap
             LLAP IO: no inputs
-        Reducer 4 
+        Reducer 2 
             Execution mode: llap
             Reduce Operator Tree:
               Group By Operator
@@ -6461,18 +6460,18 @@ STAGE PLANS:
                   alias: srcpart_orc
                   Statistics: Num rows: 2000 Data size: 564000 Basic stats: 
COMPLETE Column stats: COMPLETE
                   Select Operator
-                    expressions: ds (type: string), hr (type: int)
+                    expressions: ds (type: string), UDFToDouble(hr) (type: 
double)
                     outputColumnNames: _col0, _col1
-                    Statistics: Num rows: 2000 Data size: 376000 Basic stats: 
COMPLETE Column stats: COMPLETE
+                    Statistics: Num rows: 2000 Data size: 384000 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Map Join Operator
                       condition map:
                            Inner Join 0 to 1
                       keys:
-                        0 _col0 (type: string), UDFToDouble(_col1) (type: 
double)
-                        1 _col0 (type: string), UDFToDouble(_col2) (type: 
double)
+                        0 _col0 (type: string), _col1 (type: double)
+                        1 _col0 (type: string), _col1 (type: double)
                       input vertices:
                         1 Map 3
-                      Statistics: Num rows: 2200 Data size: 413600 Basic 
stats: COMPLETE Column stats: NONE
+                      Statistics: Num rows: 2200 Data size: 422400 Basic 
stats: COMPLETE Column stats: NONE
                       Group By Operator
                         aggregations: count()
                         mode: hash
@@ -6494,13 +6493,13 @@ STAGE PLANS:
                     predicate: ((UDFToDouble(hour) = 11.0D) and (date) IN 
('2008-04-08', '2008-04-09') and ds is not null and hr is not null) (type: 
boolean)
                     Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                     Select Operator
-                      expressions: ds (type: string), hr (type: string)
-                      outputColumnNames: _col0, _col2
+                      expressions: ds (type: string), UDFToDouble(hr) (type: 
double)
+                      outputColumnNames: _col0, _col1
                       Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Reduce Output Operator
-                        key expressions: _col0 (type: string), 
UDFToDouble(_col2) (type: double)
+                        key expressions: _col0 (type: string), _col1 (type: 
double)
                         sort order: ++
-                        Map-reduce partition columns: _col0 (type: string), 
UDFToDouble(_col2) (type: double)
+                        Map-reduce partition columns: _col0 (type: string), 
_col1 (type: double)
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                       Select Operator
                         expressions: _col0 (type: string)
@@ -6518,7 +6517,7 @@ STAGE PLANS:
                             Statistics: Num rows: 2 Data size: 1472 Basic 
stats: COMPLETE Column stats: NONE
                             Target Vertex: Map 1
                       Select Operator
-                        expressions: UDFToDouble(_col2) (type: double)
+                        expressions: _col1 (type: double)
                         outputColumnNames: _col0
                         Statistics: Num rows: 2 Data size: 1472 Basic stats: 
COMPLETE Column stats: NONE
                         Group By Operator

http://git-wip-us.apache.org/repos/asf/hive/blob/55887646/ql/src/test/results/clientpositive/llap/dynamic_semijoin_reduction_2.q.out
----------------------------------------------------------------------
diff --git 
a/ql/src/test/results/clientpositive/llap/dynamic_semijoin_reduction_2.q.out 
b/ql/src/test/results/clientpositive/llap/dynamic_semijoin_reduction_2.q.out
index 2810fdd..096751c 100644
--- a/ql/src/test/results/clientpositive/llap/dynamic_semijoin_reduction_2.q.out
+++ b/ql/src/test/results/clientpositive/llap/dynamic_semijoin_reduction_2.q.out
@@ -601,13 +601,13 @@ STAGE PLANS:
                     Statistics: Num rows: 8 Data size: 1400 Basic stats: 
COMPLETE Column stats: COMPLETE
                     Select Operator
                       expressions: value (type: string)
-                      outputColumnNames: _col1
-                      Statistics: Num rows: 8 Data size: 1400 Basic stats: 
COMPLETE Column stats: COMPLETE
+                      outputColumnNames: _col0
+                      Statistics: Num rows: 8 Data size: 712 Basic stats: 
COMPLETE Column stats: COMPLETE
                       Reduce Output Operator
-                        key expressions: _col1 (type: string)
+                        key expressions: _col0 (type: string)
                         sort order: +
-                        Map-reduce partition columns: _col1 (type: string)
-                        Statistics: Num rows: 8 Data size: 1400 Basic stats: 
COMPLETE Column stats: COMPLETE
+                        Map-reduce partition columns: _col0 (type: string)
+                        Statistics: Num rows: 8 Data size: 712 Basic stats: 
COMPLETE Column stats: COMPLETE
             Execution mode: vectorized, llap
             LLAP IO: no inputs
         Reducer 2 
@@ -662,7 +662,7 @@ STAGE PLANS:
                      Inner Join 0 to 1
                 keys:
                   0 _col1 (type: string)
-                  1 _col1 (type: string)
+                  1 _col0 (type: string)
                 Statistics: Num rows: 1 Data size: 8 Basic stats: COMPLETE 
Column stats: COMPLETE
                 Group By Operator
                   aggregations: count()

http://git-wip-us.apache.org/repos/asf/hive/blob/55887646/ql/src/test/results/clientpositive/llap/explainanalyze_2.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/llap/explainanalyze_2.q.out 
b/ql/src/test/results/clientpositive/llap/explainanalyze_2.q.out
index 9332e71..36bd120 100644
--- a/ql/src/test/results/clientpositive/llap/explainanalyze_2.q.out
+++ b/ql/src/test/results/clientpositive/llap/explainanalyze_2.q.out
@@ -74,12 +74,12 @@ Stage-0
               Select Operator [SEL_124] (rows=66/61 width=268)
                 Output:["_col0","_col1","_col2"]
                 Merge Join Operator [MERGEJOIN_123] (rows=66/61 width=268)
-                  
Conds:RS_21._col3=RS_22._col1(Inner),Output:["_col1","_col2","_col5"]
+                  
Conds:RS_21._col3=RS_22._col0(Inner),Output:["_col1","_col2","_col4"]
                 <-Reducer 11 [SIMPLE_EDGE] llap
                   SHUFFLE [RS_22]
-                    PartitionCols:_col1
-                    Select Operator [SEL_17] (rows=525/319 width=178)
-                      Output:["_col1"]
+                    PartitionCols:_col0
+                    Select Operator [SEL_17] (rows=525/319 width=91)
+                      Output:["_col0"]
                       Group By Operator [GBY_16] (rows=525/319 width=178)
                         Output:["_col0","_col1"],keys:KEY._col0, KEY._col1
                       <-Union 10 [SIMPLE_EDGE]
@@ -130,12 +130,12 @@ Stage-0
               Select Operator [SEL_128] (rows=66/61 width=268)
                 Output:["_col0","_col1","_col2"]
                 Merge Join Operator [MERGEJOIN_127] (rows=66/61 width=268)
-                  
Conds:RS_46._col3=RS_47._col1(Inner),Output:["_col1","_col2","_col5"]
+                  
Conds:RS_46._col3=RS_47._col0(Inner),Output:["_col1","_col2","_col4"]
                 <-Reducer 15 [SIMPLE_EDGE] llap
                   SHUFFLE [RS_47]
-                    PartitionCols:_col1
-                    Select Operator [SEL_42] (rows=525/319 width=178)
-                      Output:["_col1"]
+                    PartitionCols:_col0
+                    Select Operator [SEL_42] (rows=525/319 width=91)
+                      Output:["_col0"]
                       Group By Operator [GBY_41] (rows=525/319 width=178)
                         Output:["_col0","_col1"],keys:KEY._col0, KEY._col1
                       <-Union 14 [SIMPLE_EDGE]
@@ -280,12 +280,12 @@ Stage-0
                     Select Operator [SEL_235] (rows=130/61 width=177)
                       Output:["_col0","_col1"]
                       Merge Join Operator [MERGEJOIN_234] (rows=130/61 
width=177)
-                        
Conds:RS_55._col3=RS_56._col1(Inner),Output:["_col1","_col2"]
+                        
Conds:RS_55._col3=RS_56._col0(Inner),Output:["_col1","_col2"]
                       <-Reducer 20 [SIMPLE_EDGE] llap
                         SHUFFLE [RS_56]
-                          PartitionCols:_col1
-                          Select Operator [SEL_51] (rows=1025/319 width=178)
-                            Output:["_col1"]
+                          PartitionCols:_col0
+                          Select Operator [SEL_51] (rows=1025/319 width=91)
+                            Output:["_col0"]
                             Group By Operator [GBY_50] (rows=1025/319 
width=178)
                               Output:["_col0","_col1"],keys:KEY._col0, 
KEY._col1
                             <-Union 19 [SIMPLE_EDGE]
@@ -353,7 +353,7 @@ Stage-0
                     Select Operator [SEL_224] (rows=66/61 width=177)
                       Output:["_col0","_col1"]
                       Merge Join Operator [MERGEJOIN_223] (rows=66/61 
width=177)
-                        
Conds:RS_21._col3=RS_22._col1(Inner),Output:["_col1","_col2"]
+                        
Conds:RS_21._col3=RS_22._col0(Inner),Output:["_col1","_col2"]
                       <-Reducer 2 [SIMPLE_EDGE] llap
                         SHUFFLE [RS_21]
                           PartitionCols:_col3
@@ -369,9 +369,9 @@ Stage-0
                                Please refer to the previous Select Operator 
[SEL_5]
                       <-Reducer 14 [SIMPLE_EDGE] llap
                         SHUFFLE [RS_22]
-                          PartitionCols:_col1
-                          Select Operator [SEL_17] (rows=525/319 width=178)
-                            Output:["_col1"]
+                          PartitionCols:_col0
+                          Select Operator [SEL_17] (rows=525/319 width=91)
+                            Output:["_col0"]
                             Group By Operator [GBY_16] (rows=525/319 width=178)
                               Output:["_col0","_col1"],keys:KEY._col0, 
KEY._col1
                             <-Union 13 [SIMPLE_EDGE]
@@ -399,16 +399,16 @@ Stage-0
               Select Operator [SEL_231] (rows=193/61 width=177)
                 Output:["_col0","_col1"]
                 Merge Join Operator [MERGEJOIN_230] (rows=193/61 width=177)
-                  
Conds:RS_104._col3=RS_105._col1(Inner),Output:["_col1","_col2"]
+                  
Conds:RS_104._col3=RS_105._col0(Inner),Output:["_col1","_col2"]
                 <-Reducer 2 [SIMPLE_EDGE] llap
                   SHUFFLE [RS_104]
                     PartitionCols:_col3
                      Please refer to the previous Merge Join Operator 
[MERGEJOIN_217]
                 <-Reducer 29 [SIMPLE_EDGE] llap
                   SHUFFLE [RS_105]
-                    PartitionCols:_col1
-                    Select Operator [SEL_100] (rows=1525/319 width=178)
-                      Output:["_col1"]
+                    PartitionCols:_col0
+                    Select Operator [SEL_100] (rows=1525/319 width=91)
+                      Output:["_col0"]
                       Group By Operator [GBY_99] (rows=1525/319 width=178)
                         Output:["_col0","_col1"],keys:KEY._col0, KEY._col1
                       <-Union 28 [SIMPLE_EDGE]
@@ -1595,7 +1595,7 @@ Stage-5
                             Select Operator [SEL_258] (rows=193/304 width=175)
                               Output:["_col0","_col1"]
                               Merge Join Operator [MERGEJOIN_257] 
(rows=193/304 width=175)
-                                
Conds:RS_104._col1=RS_105._col1(Inner),Output:["_col0","_col3"]
+                                
Conds:RS_104._col1=RS_105._col0(Inner),Output:["_col0","_col3"]
                               <-Reducer 14 [SIMPLE_EDGE] llap
                                 SHUFFLE [RS_104]
                                   PartitionCols:_col1
@@ -1621,9 +1621,9 @@ Stage-5
                                             
default@src1,y,Tbl:COMPLETE,Col:COMPLETE,Output:["key","value"]
                               <-Reducer 35 [SIMPLE_EDGE] llap
                                 SHUFFLE [RS_105]
-                                  PartitionCols:_col1
-                                  Select Operator [SEL_100] (rows=1525/319 
width=178)
-                                    Output:["_col1"]
+                                  PartitionCols:_col0
+                                  Select Operator [SEL_100] (rows=1525/319 
width=91)
+                                    Output:["_col0"]
                                     Group By Operator [GBY_99] (rows=1525/319 
width=178)
                                       Output:["_col0","_col1"],keys:KEY._col0, 
KEY._col1
                                     <-Union 34 [SIMPLE_EDGE]
@@ -1691,7 +1691,7 @@ Stage-5
                                   Select Operator [SEL_254] (rows=2640/1056 
width=178)
                                     Output:["_col0","_col1"]
                                     Merge Join Operator [MERGEJOIN_253] 
(rows=2640/1056 width=178)
-                                      
Conds:RS_55._col1=RS_56._col1(Inner),Output:["_col0","_col3"]
+                                      
Conds:RS_55._col1=RS_56._col0(Inner),Output:["_col0","_col3"]
                                     <-Reducer 11 [SIMPLE_EDGE] llap
                                       SHUFFLE [RS_55]
                                         PartitionCols:_col1
@@ -1717,9 +1717,9 @@ Stage-5
                                                   
default@src,y,Tbl:COMPLETE,Col:COMPLETE,Output:["key","value"]
                                     <-Reducer 25 [SIMPLE_EDGE] llap
                                       SHUFFLE [RS_56]
-                                        PartitionCols:_col1
-                                        Select Operator [SEL_51] 
(rows=1025/319 width=178)
-                                          Output:["_col1"]
+                                        PartitionCols:_col0
+                                        Select Operator [SEL_51] 
(rows=1025/319 width=91)
+                                          Output:["_col0"]
                                           Group By Operator [GBY_50] 
(rows=1025/319 width=178)
                                             
Output:["_col0","_col1"],keys:KEY._col0, KEY._col1
                                           <-Union 24 [SIMPLE_EDGE]
@@ -1764,12 +1764,12 @@ Stage-5
                                   Select Operator [SEL_247] (rows=66/61 
width=177)
                                     Output:["_col0","_col1"]
                                     Merge Join Operator [MERGEJOIN_246] 
(rows=66/61 width=177)
-                                      
Conds:RS_21._col3=RS_22._col1(Inner),Output:["_col1","_col2"]
+                                      
Conds:RS_21._col3=RS_22._col0(Inner),Output:["_col1","_col2"]
                                     <-Reducer 18 [SIMPLE_EDGE] llap
                                       SHUFFLE [RS_22]
-                                        PartitionCols:_col1
-                                        Select Operator [SEL_17] (rows=525/319 
width=178)
-                                          Output:["_col1"]
+                                        PartitionCols:_col0
+                                        Select Operator [SEL_17] (rows=525/319 
width=91)
+                                          Output:["_col0"]
                                           Group By Operator [GBY_16] 
(rows=525/319 width=178)
                                             
Output:["_col0","_col1"],keys:KEY._col0, KEY._col1
                                           <-Union 17 [SIMPLE_EDGE]

Reply via email to