HIVE-18797 : ExprConstNodeDesc's getExprString should put appropriate qualifier with...
[hive.git] / ql / src / test / results / clientpositive / perf / tez / query86.q.out
1 PREHOOK: query: explain
2 select   
3     sum(ws_net_paid) as total_sum
4    ,i_category
5    ,i_class
6    ,grouping(i_category)+grouping(i_class) as lochierarchy
7    ,rank() over (
8         partition by grouping(i_category)+grouping(i_class),
9         case when grouping(i_class) = 0 then i_category end 
10         order by sum(ws_net_paid) desc) as rank_within_parent
11  from
12     web_sales
13    ,date_dim       d1
14    ,item
15  where
16     d1.d_month_seq between 1212 and 1212+11
17  and d1.d_date_sk = ws_sold_date_sk
18  and i_item_sk  = ws_item_sk
19  group by rollup(i_category,i_class)
20  order by
21    lochierarchy desc,
22    case when lochierarchy = 0 then i_category end,
23    rank_within_parent
24  limit 100
25 PREHOOK: type: QUERY
26 POSTHOOK: query: explain
27 select   
28     sum(ws_net_paid) as total_sum
29    ,i_category
30    ,i_class
31    ,grouping(i_category)+grouping(i_class) as lochierarchy
32    ,rank() over (
33         partition by grouping(i_category)+grouping(i_class),
34         case when grouping(i_class) = 0 then i_category end 
35         order by sum(ws_net_paid) desc) as rank_within_parent
36  from
37     web_sales
38    ,date_dim       d1
39    ,item
40  where
41     d1.d_month_seq between 1212 and 1212+11
42  and d1.d_date_sk = ws_sold_date_sk
43  and i_item_sk  = ws_item_sk
44  group by rollup(i_category,i_class)
45  order by
46    lochierarchy desc,
47    case when lochierarchy = 0 then i_category end,
48    rank_within_parent
49  limit 100
50 POSTHOOK: type: QUERY
51 Plan optimized by CBO.
52
53 Vertex dependency in root stage
54 Reducer 2 <- Map 1 (SIMPLE_EDGE), Map 7 (SIMPLE_EDGE)
55 Reducer 3 <- Map 8 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
56 Reducer 4 <- Reducer 3 (SIMPLE_EDGE)
57 Reducer 5 <- Reducer 4 (SIMPLE_EDGE)
58 Reducer 6 <- Reducer 5 (SIMPLE_EDGE)
59
60 Stage-0
61   Fetch Operator
62     limit:-1
63     Stage-1
64       Reducer 6
65       File Output Operator [FS_30]
66         Limit [LIM_28] (rows=100 width=135)
67           Number of rows:100
68           Select Operator [SEL_27] (rows=261364852 width=135)
69             Output:["_col0","_col1","_col2","_col3","_col4"]
70           <-Reducer 5 [SIMPLE_EDGE]
71             SHUFFLE [RS_26]
72               Select Operator [SEL_24] (rows=261364852 width=135)
73                 Output:["_col0","_col1","_col2","_col3","_col4","_col5"]
74                 PTF Operator [PTF_23] (rows=261364852 width=135)
75                   Function definitions:[{},{"name:":"windowingtablefunction","order by:":"_col2 DESC NULLS LAST","partition by:":"(grouping(_col3, 1) + grouping(_col3, 0)), CASE WHEN ((grouping(_col3, 0) = 0)) THEN (_col0) ELSE (UDFToString(null)) END"}]
76                   Select Operator [SEL_22] (rows=261364852 width=135)
77                     Output:["_col0","_col1","_col2","_col3"]
78                   <-Reducer 4 [SIMPLE_EDGE]
79                     SHUFFLE [RS_21]
80                       PartitionCols:(grouping(_col3, 1) + grouping(_col3, 0)), CASE WHEN ((grouping(_col3, 0) = 0)) THEN (_col0) ELSE (UDFToString(null)) END
81                       Select Operator [SEL_20] (rows=261364852 width=135)
82                         Output:["_col0","_col1","_col2","_col3"]
83                         Group By Operator [GBY_19] (rows=261364852 width=135)
84                           Output:["_col0","_col1","_col2","_col3"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0, KEY._col1, KEY._col2
85                         <-Reducer 3 [SIMPLE_EDGE]
86                           SHUFFLE [RS_18]
87                             PartitionCols:_col0, _col1, _col2
88                             Group By Operator [GBY_17] (rows=522729705 width=135)
89                               Output:["_col0","_col1","_col2","_col3"],aggregations:["sum(_col2)"],keys:_col0, _col1, 0L
90                               Select Operator [SEL_15] (rows=174243235 width=135)
91                                 Output:["_col0","_col1","_col2"]
92                                 Merge Join Operator [MERGEJOIN_40] (rows=174243235 width=135)
93                                   Conds:RS_12._col1=RS_13._col0(Inner),Output:["_col2","_col6","_col7"]
94                                 <-Map 8 [SIMPLE_EDGE]
95                                   SHUFFLE [RS_13]
96                                     PartitionCols:_col0
97                                     Select Operator [SEL_8] (rows=462000 width=1436)
98                                       Output:["_col0","_col1","_col2"]
99                                       Filter Operator [FIL_38] (rows=462000 width=1436)
100                                         predicate:i_item_sk is not null
101                                         TableScan [TS_6] (rows=462000 width=1436)
102                                           default@item,item,Tbl:COMPLETE,Col:NONE,Output:["i_item_sk","i_class","i_category"]
103                                 <-Reducer 2 [SIMPLE_EDGE]
104                                   SHUFFLE [RS_12]
105                                     PartitionCols:_col1
106                                     Merge Join Operator [MERGEJOIN_39] (rows=158402938 width=135)
107                                       Conds:RS_9._col0=RS_10._col0(Inner),Output:["_col1","_col2"]
108                                     <-Map 1 [SIMPLE_EDGE]
109                                       SHUFFLE [RS_9]
110                                         PartitionCols:_col0
111                                         Select Operator [SEL_2] (rows=144002668 width=135)
112                                           Output:["_col0","_col1","_col2"]
113                                           Filter Operator [FIL_36] (rows=144002668 width=135)
114                                             predicate:(ws_item_sk is not null and ws_sold_date_sk is not null)
115                                             TableScan [TS_0] (rows=144002668 width=135)
116                                               default@web_sales,web_sales,Tbl:COMPLETE,Col:NONE,Output:["ws_sold_date_sk","ws_item_sk","ws_net_paid"]
117                                     <-Map 7 [SIMPLE_EDGE]
118                                       SHUFFLE [RS_10]
119                                         PartitionCols:_col0
120                                         Select Operator [SEL_5] (rows=8116 width=1119)
121                                           Output:["_col0"]
122                                           Filter Operator [FIL_37] (rows=8116 width=1119)
123                                             predicate:(d_date_sk is not null and d_month_seq BETWEEN 1212 AND 1223)
124                                             TableScan [TS_3] (rows=73049 width=1119)
125                                               default@date_dim,d1,Tbl:COMPLETE,Col:NONE,Output:["d_date_sk","d_month_seq"]
126