PageRenderTime 27ms CodeModel.GetById 17ms app.highlight 6ms RepoModel.GetById 2ms app.codeStats 0ms

/tags/release-0.2.0-rc0/hive/external/ql/src/test/results/clientpositive/join35.q.out

#
text | 620 lines | 603 code | 17 blank | 0 comment | 0 complexity | 06655e99609b5e9631534c60bfae7927 MD5 | raw file
  1PREHOOK: query: CREATE TABLE dest_j1(key STRING, value STRING, val2 INT) STORED AS TEXTFILE
  2PREHOOK: type: CREATETABLE
  3POSTHOOK: query: CREATE TABLE dest_j1(key STRING, value STRING, val2 INT) STORED AS TEXTFILE
  4POSTHOOK: type: CREATETABLE
  5POSTHOOK: Output: default@dest_j1
  6PREHOOK: query: EXPLAIN EXTENDED
  7INSERT OVERWRITE TABLE dest_j1
  8SELECT /*+ MAPJOIN(x) */ x.key, x.value, subq1.cnt
  9FROM 
 10( SELECT x.key as key, count(1) as cnt from src x where x.key < 20 group by x.key
 11     UNION ALL
 12  SELECT x1.key as key, count(1) as cnt from src x1 where x1.key > 100 group by x1.key
 13) subq1
 14JOIN src1 x ON (x.key = subq1.key)
 15PREHOOK: type: QUERY
 16POSTHOOK: query: EXPLAIN EXTENDED
 17INSERT OVERWRITE TABLE dest_j1
 18SELECT /*+ MAPJOIN(x) */ x.key, x.value, subq1.cnt
 19FROM 
 20( SELECT x.key as key, count(1) as cnt from src x where x.key < 20 group by x.key
 21     UNION ALL
 22  SELECT x1.key as key, count(1) as cnt from src x1 where x1.key > 100 group by x1.key
 23) subq1
 24JOIN src1 x ON (x.key = subq1.key)
 25POSTHOOK: type: QUERY
 26ABSTRACT SYNTAX TREE:
 27  (TOK_QUERY (TOK_FROM (TOK_JOIN (TOK_SUBQUERY (TOK_UNION (TOK_QUERY (TOK_FROM (TOK_TABREF (TOK_TABNAME src) x)) (TOK_INSERT (TOK_DESTINATION (TOK_DIR TOK_TMP_FILE)) (TOK_SELECT (TOK_SELEXPR (. (TOK_TABLE_OR_COL x) key) key) (TOK_SELEXPR (TOK_FUNCTION count 1) cnt)) (TOK_WHERE (< (. (TOK_TABLE_OR_COL x) key) 20)) (TOK_GROUPBY (. (TOK_TABLE_OR_COL x) key)))) (TOK_QUERY (TOK_FROM (TOK_TABREF (TOK_TABNAME src) x1)) (TOK_INSERT (TOK_DESTINATION (TOK_DIR TOK_TMP_FILE)) (TOK_SELECT (TOK_SELEXPR (. (TOK_TABLE_OR_COL x1) key) key) (TOK_SELEXPR (TOK_FUNCTION count 1) cnt)) (TOK_WHERE (> (. (TOK_TABLE_OR_COL x1) key) 100)) (TOK_GROUPBY (. (TOK_TABLE_OR_COL x1) key))))) subq1) (TOK_TABREF (TOK_TABNAME src1) x) (= (. (TOK_TABLE_OR_COL x) key) (. (TOK_TABLE_OR_COL subq1) key)))) (TOK_INSERT (TOK_DESTINATION (TOK_TAB (TOK_TABNAME dest_j1))) (TOK_SELECT (TOK_HINTLIST (TOK_HINT TOK_MAPJOIN (TOK_HINTARGLIST x))) (TOK_SELEXPR (. (TOK_TABLE_OR_COL x) key)) (TOK_SELEXPR (. (TOK_TABLE_OR_COL x) value)) (TOK_SELEXPR (. (TOK_TABLE_OR_COL subq1) cnt)))))
 28
 29STAGE DEPENDENCIES:
 30  Stage-1 is a root stage
 31  Stage-9 depends on stages: Stage-1, Stage-7
 32  Stage-2 depends on stages: Stage-9
 33  Stage-6 depends on stages: Stage-2 , consists of Stage-5, Stage-4
 34  Stage-5
 35  Stage-0 depends on stages: Stage-5, Stage-4
 36  Stage-3 depends on stages: Stage-0
 37  Stage-4
 38  Stage-7 is a root stage
 39
 40STAGE PLANS:
 41  Stage: Stage-1
 42    Map Reduce
 43      Alias -> Map Operator Tree:
 44        null-subquery1:subq1-subquery1:x 
 45          TableScan
 46            alias: x
 47            GatherStats: false
 48            Filter Operator
 49              isSamplingPred: false
 50              predicate:
 51                  expr: (key < 20)
 52                  type: boolean
 53              Select Operator
 54                expressions:
 55                      expr: key
 56                      type: string
 57                outputColumnNames: key
 58                Group By Operator
 59                  aggregations:
 60                        expr: count(1)
 61                  bucketGroup: false
 62                  keys:
 63                        expr: key
 64                        type: string
 65                  mode: hash
 66                  outputColumnNames: _col0, _col1
 67                  Reduce Output Operator
 68                    key expressions:
 69                          expr: _col0
 70                          type: string
 71                    sort order: +
 72                    Map-reduce partition columns:
 73                          expr: _col0
 74                          type: string
 75                    tag: -1
 76                    value expressions:
 77                          expr: _col1
 78                          type: bigint
 79      Needs Tagging: false
 80      Path -> Alias:
 81        pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/src [null-subquery1:subq1-subquery1:x]
 82      Path -> Partition:
 83        pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/src 
 84          Partition
 85            base file name: src
 86            input format: org.apache.hadoop.mapred.TextInputFormat
 87            output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
 88            properties:
 89              bucket_count -1
 90              columns key,value
 91              columns.types string:string
 92              file.inputformat org.apache.hadoop.mapred.TextInputFormat
 93              file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
 94              location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/src
 95              name default.src
 96              serialization.ddl struct src { string key, string value}
 97              serialization.format 1
 98              serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
 99              transient_lastDdlTime 1297378968
100            serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
101          
102              input format: org.apache.hadoop.mapred.TextInputFormat
103              output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
104              properties:
105                bucket_count -1
106                columns key,value
107                columns.types string:string
108                file.inputformat org.apache.hadoop.mapred.TextInputFormat
109                file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
110                location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/src
111                name default.src
112                serialization.ddl struct src { string key, string value}
113                serialization.format 1
114                serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
115                transient_lastDdlTime 1297378968
116              serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
117              name: default.src
118            name: default.src
119      Reduce Operator Tree:
120        Group By Operator
121          aggregations:
122                expr: count(VALUE._col0)
123          bucketGroup: false
124          keys:
125                expr: KEY._col0
126                type: string
127          mode: mergepartial
128          outputColumnNames: _col0, _col1
129          Select Operator
130            expressions:
131                  expr: _col0
132                  type: string
133                  expr: _col1
134                  type: bigint
135            outputColumnNames: _col0, _col1
136            File Output Operator
137              compressed: false
138              GlobalTableId: 0
139              directory: file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10002
140              NumFilesPerFileSink: 1
141              table:
142                  input format: org.apache.hadoop.mapred.SequenceFileInputFormat
143                  output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
144                  properties:
145                    columns _col0,_col1
146                    columns.types string,bigint
147                    escape.delim \
148              TotalFiles: 1
149              GatherStats: false
150              MultiFileSpray: false
151
152  Stage: Stage-9
153    Map Reduce Local Work
154      Alias -> Map Local Tables:
155        x 
156          Fetch Operator
157            limit: -1
158      Alias -> Map Local Operator Tree:
159        x 
160          TableScan
161            alias: x
162            GatherStats: false
163            HashTable Sink Operator
164              condition expressions:
165                0 {_col1}
166                1 {key} {value}
167              handleSkewJoin: false
168              keys:
169                0 [Column[_col0]]
170                1 [Column[key]]
171              Position of Big Table: 0
172
173  Stage: Stage-2
174    Map Reduce
175      Alias -> Map Operator Tree:
176        file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10002 
177          Union
178            Map Join Operator
179              condition map:
180                   Inner Join 0 to 1
181              condition expressions:
182                0 {_col1}
183                1 {key} {value}
184              handleSkewJoin: false
185              keys:
186                0 [Column[_col0]]
187                1 [Column[key]]
188              outputColumnNames: _col1, _col2, _col3
189              Position of Big Table: 0
190              Select Operator
191                expressions:
192                      expr: _col1
193                      type: bigint
194                      expr: _col2
195                      type: string
196                      expr: _col3
197                      type: string
198                outputColumnNames: _col1, _col2, _col3
199                Select Operator
200                  expressions:
201                        expr: _col2
202                        type: string
203                        expr: _col3
204                        type: string
205                        expr: _col1
206                        type: bigint
207                  outputColumnNames: _col0, _col1, _col2
208                  Select Operator
209                    expressions:
210                          expr: _col0
211                          type: string
212                          expr: _col1
213                          type: string
214                          expr: UDFToInteger(_col2)
215                          type: int
216                    outputColumnNames: _col0, _col1, _col2
217                    File Output Operator
218                      compressed: false
219                      GlobalTableId: 1
220                      directory: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10003
221                      NumFilesPerFileSink: 1
222                      Stats Publishing Key Prefix: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10000/
223                      table:
224                          input format: org.apache.hadoop.mapred.TextInputFormat
225                          output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
226                          properties:
227                            bucket_count -1
228                            columns key,value,val2
229                            columns.types string:string:int
230                            file.inputformat org.apache.hadoop.mapred.TextInputFormat
231                            file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
232                            location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/dest_j1
233                            name default.dest_j1
234                            serialization.ddl struct dest_j1 { string key, string value, i32 val2}
235                            serialization.format 1
236                            serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
237                            transient_lastDdlTime 1297382768
238                          serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
239                          name: default.dest_j1
240                      TotalFiles: 1
241                      GatherStats: true
242                      MultiFileSpray: false
243        file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10004 
244          Union
245            Map Join Operator
246              condition map:
247                   Inner Join 0 to 1
248              condition expressions:
249                0 {_col1}
250                1 {key} {value}
251              handleSkewJoin: false
252              keys:
253                0 [Column[_col0]]
254                1 [Column[key]]
255              outputColumnNames: _col1, _col2, _col3
256              Position of Big Table: 0
257              Select Operator
258                expressions:
259                      expr: _col1
260                      type: bigint
261                      expr: _col2
262                      type: string
263                      expr: _col3
264                      type: string
265                outputColumnNames: _col1, _col2, _col3
266                Select Operator
267                  expressions:
268                        expr: _col2
269                        type: string
270                        expr: _col3
271                        type: string
272                        expr: _col1
273                        type: bigint
274                  outputColumnNames: _col0, _col1, _col2
275                  Select Operator
276                    expressions:
277                          expr: _col0
278                          type: string
279                          expr: _col1
280                          type: string
281                          expr: UDFToInteger(_col2)
282                          type: int
283                    outputColumnNames: _col0, _col1, _col2
284                    File Output Operator
285                      compressed: false
286                      GlobalTableId: 1
287                      directory: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10003
288                      NumFilesPerFileSink: 1
289                      Stats Publishing Key Prefix: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10000/
290                      table:
291                          input format: org.apache.hadoop.mapred.TextInputFormat
292                          output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
293                          properties:
294                            bucket_count -1
295                            columns key,value,val2
296                            columns.types string:string:int
297                            file.inputformat org.apache.hadoop.mapred.TextInputFormat
298                            file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
299                            location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/dest_j1
300                            name default.dest_j1
301                            serialization.ddl struct dest_j1 { string key, string value, i32 val2}
302                            serialization.format 1
303                            serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
304                            transient_lastDdlTime 1297382768
305                          serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
306                          name: default.dest_j1
307                      TotalFiles: 1
308                      GatherStats: true
309                      MultiFileSpray: false
310      Local Work:
311        Map Reduce Local Work
312      Needs Tagging: false
313      Path -> Alias:
314        file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10002 [file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10002]
315        file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10004 [file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10004]
316      Path -> Partition:
317        file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10002 
318          Partition
319            base file name: -mr-10002
320            input format: org.apache.hadoop.mapred.SequenceFileInputFormat
321            output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
322            properties:
323              columns _col0,_col1
324              columns.types string,bigint
325              escape.delim \
326          
327              input format: org.apache.hadoop.mapred.SequenceFileInputFormat
328              output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
329              properties:
330                columns _col0,_col1
331                columns.types string,bigint
332                escape.delim \
333        file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10004 
334          Partition
335            base file name: -mr-10004
336            input format: org.apache.hadoop.mapred.SequenceFileInputFormat
337            output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
338            properties:
339              columns _col0,_col1
340              columns.types string,bigint
341              escape.delim \
342          
343              input format: org.apache.hadoop.mapred.SequenceFileInputFormat
344              output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
345              properties:
346                columns _col0,_col1
347                columns.types string,bigint
348                escape.delim \
349
350  Stage: Stage-6
351    Conditional Operator
352
353  Stage: Stage-5
354    Move Operator
355      files:
356          hdfs directory: true
357          source: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10003
358          destination: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10000
359
360  Stage: Stage-0
361    Move Operator
362      tables:
363          replace: true
364          source: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10000
365          table:
366              input format: org.apache.hadoop.mapred.TextInputFormat
367              output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
368              properties:
369                bucket_count -1
370                columns key,value,val2
371                columns.types string:string:int
372                file.inputformat org.apache.hadoop.mapred.TextInputFormat
373                file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
374                location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/dest_j1
375                name default.dest_j1
376                serialization.ddl struct dest_j1 { string key, string value, i32 val2}
377                serialization.format 1
378                serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
379                transient_lastDdlTime 1297382768
380              serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
381              name: default.dest_j1
382          tmp directory: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10001
383
384  Stage: Stage-3
385    Stats-Aggr Operator
386      Stats Aggregation Key Prefix: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10000/
387
388  Stage: Stage-4
389    Map Reduce
390      Alias -> Map Operator Tree:
391        pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10003 
392            File Output Operator
393              compressed: false
394              GlobalTableId: 0
395              directory: pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10000
396              NumFilesPerFileSink: 1
397              table:
398                  input format: org.apache.hadoop.mapred.TextInputFormat
399                  output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
400                  properties:
401                    bucket_count -1
402                    columns key,value,val2
403                    columns.types string:string:int
404                    file.inputformat org.apache.hadoop.mapred.TextInputFormat
405                    file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
406                    location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/dest_j1
407                    name default.dest_j1
408                    serialization.ddl struct dest_j1 { string key, string value, i32 val2}
409                    serialization.format 1
410                    serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
411                    transient_lastDdlTime 1297382768
412                  serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
413                  name: default.dest_j1
414              TotalFiles: 1
415              GatherStats: false
416              MultiFileSpray: false
417      Needs Tagging: false
418      Path -> Alias:
419        pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10003 [pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10003]
420      Path -> Partition:
421        pfile:/data/users/sdong/www/open-source-hive1/build/ql/scratchdir/hive_2011-02-10_16-06-08_256_5728117320203012463/-ext-10003 
422          Partition
423            base file name: -ext-10003
424            input format: org.apache.hadoop.mapred.TextInputFormat
425            output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
426            properties:
427              bucket_count -1
428              columns key,value,val2
429              columns.types string:string:int
430              file.inputformat org.apache.hadoop.mapred.TextInputFormat
431              file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
432              location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/dest_j1
433              name default.dest_j1
434              serialization.ddl struct dest_j1 { string key, string value, i32 val2}
435              serialization.format 1
436              serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
437              transient_lastDdlTime 1297382768
438            serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
439          
440              input format: org.apache.hadoop.mapred.TextInputFormat
441              output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
442              properties:
443                bucket_count -1
444                columns key,value,val2
445                columns.types string:string:int
446                file.inputformat org.apache.hadoop.mapred.TextInputFormat
447                file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
448                location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/dest_j1
449                name default.dest_j1
450                serialization.ddl struct dest_j1 { string key, string value, i32 val2}
451                serialization.format 1
452                serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
453                transient_lastDdlTime 1297382768
454              serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
455              name: default.dest_j1
456            name: default.dest_j1
457
458  Stage: Stage-7
459    Map Reduce
460      Alias -> Map Operator Tree:
461        null-subquery2:subq1-subquery2:x1 
462          TableScan
463            alias: x1
464            GatherStats: false
465            Filter Operator
466              isSamplingPred: false
467              predicate:
468                  expr: (key > 100)
469                  type: boolean
470              Select Operator
471                expressions:
472                      expr: key
473                      type: string
474                outputColumnNames: key
475                Group By Operator
476                  aggregations:
477                        expr: count(1)
478                  bucketGroup: false
479                  keys:
480                        expr: key
481                        type: string
482                  mode: hash
483                  outputColumnNames: _col0, _col1
484                  Reduce Output Operator
485                    key expressions:
486                          expr: _col0
487                          type: string
488                    sort order: +
489                    Map-reduce partition columns:
490                          expr: _col0
491                          type: string
492                    tag: -1
493                    value expressions:
494                          expr: _col1
495                          type: bigint
496      Needs Tagging: false
497      Path -> Alias:
498        pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/src [null-subquery2:subq1-subquery2:x1]
499      Path -> Partition:
500        pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/src 
501          Partition
502            base file name: src
503            input format: org.apache.hadoop.mapred.TextInputFormat
504            output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
505            properties:
506              bucket_count -1
507              columns key,value
508              columns.types string:string
509              file.inputformat org.apache.hadoop.mapred.TextInputFormat
510              file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
511              location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/src
512              name default.src
513              serialization.ddl struct src { string key, string value}
514              serialization.format 1
515              serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
516              transient_lastDdlTime 1297378968
517            serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
518          
519              input format: org.apache.hadoop.mapred.TextInputFormat
520              output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
521              properties:
522                bucket_count -1
523                columns key,value
524                columns.types string:string
525                file.inputformat org.apache.hadoop.mapred.TextInputFormat
526                file.outputformat org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
527                location pfile:/data/users/sdong/www/open-source-hive1/build/ql/test/data/warehouse/src
528                name default.src
529                serialization.ddl struct src { string key, string value}
530                serialization.format 1
531                serialization.lib org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
532                transient_lastDdlTime 1297378968
533              serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
534              name: default.src
535            name: default.src
536      Reduce Operator Tree:
537        Group By Operator
538          aggregations:
539                expr: count(VALUE._col0)
540          bucketGroup: false
541          keys:
542                expr: KEY._col0
543                type: string
544          mode: mergepartial
545          outputColumnNames: _col0, _col1
546          Select Operator
547            expressions:
548                  expr: _col0
549                  type: string
550                  expr: _col1
551                  type: bigint
552            outputColumnNames: _col0, _col1
553            File Output Operator
554              compressed: false
555              GlobalTableId: 0
556              directory: file:/tmp/sdong/hive_2011-02-10_16-06-08_256_5728117320203012463/-mr-10004
557              NumFilesPerFileSink: 1
558              table:
559                  input format: org.apache.hadoop.mapred.SequenceFileInputFormat
560                  output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
561                  properties:
562                    columns _col0,_col1
563                    columns.types string,bigint
564                    escape.delim \
565              TotalFiles: 1
566              GatherStats: false
567              MultiFileSpray: false
568
569
570PREHOOK: query: INSERT OVERWRITE TABLE dest_j1
571SELECT /*+ MAPJOIN(x) */ x.key, x.value, subq1.cnt
572FROM 
573( SELECT x.key as key, count(1) as cnt from src x where x.key < 20 group by x.key
574     UNION ALL
575  SELECT x1.key as key, count(1) as cnt from src x1 where x1.key > 100 group by x1.key
576) subq1
577JOIN src1 x ON (x.key = subq1.key)
578PREHOOK: type: QUERY
579PREHOOK: Input: default@src
580PREHOOK: Input: default@src1
581PREHOOK: Output: default@dest_j1
582POSTHOOK: query: INSERT OVERWRITE TABLE dest_j1
583SELECT /*+ MAPJOIN(x) */ x.key, x.value, subq1.cnt
584FROM 
585( SELECT x.key as key, count(1) as cnt from src x where x.key < 20 group by x.key
586     UNION ALL
587  SELECT x1.key as key, count(1) as cnt from src x1 where x1.key > 100 group by x1.key
588) subq1
589JOIN src1 x ON (x.key = subq1.key)
590POSTHOOK: type: QUERY
591POSTHOOK: Input: default@src
592POSTHOOK: Input: default@src1
593POSTHOOK: Output: default@dest_j1
594POSTHOOK: Lineage: dest_j1.key SIMPLE [(src1)x.FieldSchema(name:key, type:string, comment:default), ]
595POSTHOOK: Lineage: dest_j1.val2 EXPRESSION [(src)x.null, (src)x1.null, ]
596POSTHOOK: Lineage: dest_j1.value SIMPLE [(src1)x.FieldSchema(name:value, type:string, comment:default), ]
597PREHOOK: query: select * from dest_j1 x order by x.key
598PREHOOK: type: QUERY
599PREHOOK: Input: default@dest_j1
600PREHOOK: Output: file:/tmp/sdong/hive_2011-02-10_16-06-21_981_8339275278749703354/-mr-10000
601POSTHOOK: query: select * from dest_j1 x order by x.key
602POSTHOOK: type: QUERY
603POSTHOOK: Input: default@dest_j1
604POSTHOOK: Output: file:/tmp/sdong/hive_2011-02-10_16-06-21_981_8339275278749703354/-mr-10000
605POSTHOOK: Lineage: dest_j1.key SIMPLE [(src1)x.FieldSchema(name:key, type:string, comment:default), ]
606POSTHOOK: Lineage: dest_j1.val2 EXPRESSION [(src)x.null, (src)x1.null, ]
607POSTHOOK: Lineage: dest_j1.value SIMPLE [(src1)x.FieldSchema(name:value, type:string, comment:default), ]
608128		3
609146	val_146	2
610150	val_150	1
611213	val_213	2
612224		2
613238	val_238	2
614255	val_255	2
615273	val_273	3
616278	val_278	2
617311	val_311	3
618369		3
619401	val_401	5
620406	val_406	4