You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by jc...@apache.org on 2017/10/03 23:35:58 UTC
[2/4] hive git commit: HIVE-17432: Enable join and aggregate
materialized view rewriting (Jesus Camacho Rodriguez,
reviewed by Ashutosh Chauhan)
http://git-wip-us.apache.org/repos/asf/hive/blob/073e8473/ql/src/test/results/clientpositive/materialized_view_rewrite_ssb.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/materialized_view_rewrite_ssb.q.out b/ql/src/test/results/clientpositive/materialized_view_rewrite_ssb.q.out
new file mode 100644
index 0000000..8b67b55
--- /dev/null
+++ b/ql/src/test/results/clientpositive/materialized_view_rewrite_ssb.q.out
@@ -0,0 +1,1621 @@
+PREHOOK: query: CREATE TABLE `customer`(
+ `c_custkey` bigint,
+ `c_name` string,
+ `c_address` string,
+ `c_city` string,
+ `c_nation` string,
+ `c_region` string,
+ `c_phone` string,
+ `c_mktsegment` string,
+ primary key (`c_custkey`) disable rely)
+STORED AS ORC
+PREHOOK: type: CREATETABLE
+PREHOOK: Output: database:default
+PREHOOK: Output: default@customer
+POSTHOOK: query: CREATE TABLE `customer`(
+ `c_custkey` bigint,
+ `c_name` string,
+ `c_address` string,
+ `c_city` string,
+ `c_nation` string,
+ `c_region` string,
+ `c_phone` string,
+ `c_mktsegment` string,
+ primary key (`c_custkey`) disable rely)
+STORED AS ORC
+POSTHOOK: type: CREATETABLE
+POSTHOOK: Output: database:default
+POSTHOOK: Output: default@customer
+PREHOOK: query: CREATE TABLE `dates`(
+ `d_datekey` bigint,
+ `d_date` string,
+ `d_dayofweek` string,
+ `d_month` string,
+ `d_year` int,
+ `d_yearmonthnum` int,
+ `d_yearmonth` string,
+ `d_daynuminweek` int,
+ `d_daynuminmonth` int,
+ `d_daynuminyear` int,
+ `d_monthnuminyear` int,
+ `d_weeknuminyear` int,
+ `d_sellingseason` string,
+ `d_lastdayinweekfl` int,
+ `d_lastdayinmonthfl` int,
+ `d_holidayfl` int ,
+ `d_weekdayfl`int,
+ primary key (`d_datekey`) disable rely
+)
+STORED AS ORC
+PREHOOK: type: CREATETABLE
+PREHOOK: Output: database:default
+PREHOOK: Output: default@dates
+POSTHOOK: query: CREATE TABLE `dates`(
+ `d_datekey` bigint,
+ `d_date` string,
+ `d_dayofweek` string,
+ `d_month` string,
+ `d_year` int,
+ `d_yearmonthnum` int,
+ `d_yearmonth` string,
+ `d_daynuminweek` int,
+ `d_daynuminmonth` int,
+ `d_daynuminyear` int,
+ `d_monthnuminyear` int,
+ `d_weeknuminyear` int,
+ `d_sellingseason` string,
+ `d_lastdayinweekfl` int,
+ `d_lastdayinmonthfl` int,
+ `d_holidayfl` int ,
+ `d_weekdayfl`int,
+ primary key (`d_datekey`) disable rely
+)
+STORED AS ORC
+POSTHOOK: type: CREATETABLE
+POSTHOOK: Output: database:default
+POSTHOOK: Output: default@dates
+PREHOOK: query: CREATE TABLE `ssb_part`(
+ `p_partkey` bigint,
+ `p_name` string,
+ `p_mfgr` string,
+ `p_category` string,
+ `p_brand1` string,
+ `p_color` string,
+ `p_type` string,
+ `p_size` int,
+ `p_container` string,
+ primary key (`p_partkey`) disable rely)
+STORED AS ORC
+PREHOOK: type: CREATETABLE
+PREHOOK: Output: database:default
+PREHOOK: Output: default@ssb_part
+POSTHOOK: query: CREATE TABLE `ssb_part`(
+ `p_partkey` bigint,
+ `p_name` string,
+ `p_mfgr` string,
+ `p_category` string,
+ `p_brand1` string,
+ `p_color` string,
+ `p_type` string,
+ `p_size` int,
+ `p_container` string,
+ primary key (`p_partkey`) disable rely)
+STORED AS ORC
+POSTHOOK: type: CREATETABLE
+POSTHOOK: Output: database:default
+POSTHOOK: Output: default@ssb_part
+PREHOOK: query: CREATE TABLE `supplier`(
+ `s_suppkey` bigint,
+ `s_name` string,
+ `s_address` string,
+ `s_city` string,
+ `s_nation` string,
+ `s_region` string,
+ `s_phone` string,
+ primary key (`s_suppkey`) disable rely)
+STORED AS ORC
+PREHOOK: type: CREATETABLE
+PREHOOK: Output: database:default
+PREHOOK: Output: default@supplier
+POSTHOOK: query: CREATE TABLE `supplier`(
+ `s_suppkey` bigint,
+ `s_name` string,
+ `s_address` string,
+ `s_city` string,
+ `s_nation` string,
+ `s_region` string,
+ `s_phone` string,
+ primary key (`s_suppkey`) disable rely)
+STORED AS ORC
+POSTHOOK: type: CREATETABLE
+POSTHOOK: Output: database:default
+POSTHOOK: Output: default@supplier
+PREHOOK: query: CREATE TABLE `lineorder`(
+ `lo_orderkey` bigint,
+ `lo_linenumber` int,
+ `lo_custkey` bigint not null disable rely,
+ `lo_partkey` bigint not null disable rely,
+ `lo_suppkey` bigint not null disable rely,
+ `lo_orderdate` bigint not null disable rely,
+ `lo_ordpriority` string,
+ `lo_shippriority` string,
+ `lo_quantity` double,
+ `lo_extendedprice` double,
+ `lo_ordtotalprice` double,
+ `lo_discount` double,
+ `lo_revenue` double,
+ `lo_supplycost` double,
+ `lo_tax` double,
+ `lo_commitdate` bigint,
+ `lo_shipmode` string,
+ primary key (`lo_orderkey`) disable rely,
+ constraint fk1 foreign key (`lo_custkey`) references `customer`(`c_custkey`) disable rely,
+ constraint fk2 foreign key (`lo_orderdate`) references `dates`(`d_datekey`) disable rely,
+ constraint fk3 foreign key (`lo_partkey`) references `ssb_part`(`p_partkey`) disable rely,
+ constraint fk4 foreign key (`lo_suppkey`) references `supplier`(`s_suppkey`) disable rely)
+STORED AS ORC
+PREHOOK: type: CREATETABLE
+PREHOOK: Output: database:default
+PREHOOK: Output: default@lineorder
+POSTHOOK: query: CREATE TABLE `lineorder`(
+ `lo_orderkey` bigint,
+ `lo_linenumber` int,
+ `lo_custkey` bigint not null disable rely,
+ `lo_partkey` bigint not null disable rely,
+ `lo_suppkey` bigint not null disable rely,
+ `lo_orderdate` bigint not null disable rely,
+ `lo_ordpriority` string,
+ `lo_shippriority` string,
+ `lo_quantity` double,
+ `lo_extendedprice` double,
+ `lo_ordtotalprice` double,
+ `lo_discount` double,
+ `lo_revenue` double,
+ `lo_supplycost` double,
+ `lo_tax` double,
+ `lo_commitdate` bigint,
+ `lo_shipmode` string,
+ primary key (`lo_orderkey`) disable rely,
+ constraint fk1 foreign key (`lo_custkey`) references `customer`(`c_custkey`) disable rely,
+ constraint fk2 foreign key (`lo_orderdate`) references `dates`(`d_datekey`) disable rely,
+ constraint fk3 foreign key (`lo_partkey`) references `ssb_part`(`p_partkey`) disable rely,
+ constraint fk4 foreign key (`lo_suppkey`) references `supplier`(`s_suppkey`) disable rely)
+STORED AS ORC
+POSTHOOK: type: CREATETABLE
+POSTHOOK: Output: database:default
+POSTHOOK: Output: default@lineorder
+PREHOOK: query: analyze table customer compute statistics for columns
+PREHOOK: type: QUERY
+PREHOOK: Input: default@customer
+#### A masked pattern was here ####
+POSTHOOK: query: analyze table customer compute statistics for columns
+POSTHOOK: type: QUERY
+POSTHOOK: Input: default@customer
+#### A masked pattern was here ####
+PREHOOK: query: analyze table dates compute statistics for columns
+PREHOOK: type: QUERY
+PREHOOK: Input: default@dates
+#### A masked pattern was here ####
+POSTHOOK: query: analyze table dates compute statistics for columns
+POSTHOOK: type: QUERY
+POSTHOOK: Input: default@dates
+#### A masked pattern was here ####
+PREHOOK: query: analyze table ssb_part compute statistics for columns
+PREHOOK: type: QUERY
+PREHOOK: Input: default@ssb_part
+#### A masked pattern was here ####
+POSTHOOK: query: analyze table ssb_part compute statistics for columns
+POSTHOOK: type: QUERY
+POSTHOOK: Input: default@ssb_part
+#### A masked pattern was here ####
+PREHOOK: query: analyze table supplier compute statistics for columns
+PREHOOK: type: QUERY
+PREHOOK: Input: default@supplier
+#### A masked pattern was here ####
+POSTHOOK: query: analyze table supplier compute statistics for columns
+POSTHOOK: type: QUERY
+POSTHOOK: Input: default@supplier
+#### A masked pattern was here ####
+PREHOOK: query: analyze table lineorder compute statistics for columns
+PREHOOK: type: QUERY
+PREHOOK: Input: default@lineorder
+#### A masked pattern was here ####
+POSTHOOK: query: analyze table lineorder compute statistics for columns
+POSTHOOK: type: QUERY
+POSTHOOK: Input: default@lineorder
+#### A masked pattern was here ####
+PREHOOK: query: CREATE MATERIALIZED VIEW `ssb_mv` ENABLE REWRITE
+AS
+SELECT
+ c_city,
+ c_nation,
+ c_region,
+ d_weeknuminyear,
+ d_year,
+ d_yearmonth,
+ d_yearmonthnum,
+ lo_discount,
+ lo_quantity,
+ p_brand1,
+ p_category,
+ p_mfgr,
+ s_city,
+ s_nation,
+ s_region,
+ lo_revenue,
+ lo_extendedprice * lo_discount discounted_price,
+ lo_revenue - lo_supplycost net_revenue
+FROM
+ customer, dates, lineorder, ssb_part, supplier
+where
+ lo_orderdate = d_datekey
+ and lo_partkey = p_partkey
+ and lo_suppkey = s_suppkey
+ and lo_custkey = c_custkey
+PREHOOK: type: CREATE_MATERIALIZED_VIEW
+PREHOOK: Input: default@customer
+PREHOOK: Input: default@dates
+PREHOOK: Input: default@lineorder
+PREHOOK: Input: default@ssb_part
+PREHOOK: Input: default@supplier
+PREHOOK: Output: database:default
+PREHOOK: Output: default@ssb_mv
+POSTHOOK: query: CREATE MATERIALIZED VIEW `ssb_mv` ENABLE REWRITE
+AS
+SELECT
+ c_city,
+ c_nation,
+ c_region,
+ d_weeknuminyear,
+ d_year,
+ d_yearmonth,
+ d_yearmonthnum,
+ lo_discount,
+ lo_quantity,
+ p_brand1,
+ p_category,
+ p_mfgr,
+ s_city,
+ s_nation,
+ s_region,
+ lo_revenue,
+ lo_extendedprice * lo_discount discounted_price,
+ lo_revenue - lo_supplycost net_revenue
+FROM
+ customer, dates, lineorder, ssb_part, supplier
+where
+ lo_orderdate = d_datekey
+ and lo_partkey = p_partkey
+ and lo_suppkey = s_suppkey
+ and lo_custkey = c_custkey
+POSTHOOK: type: CREATE_MATERIALIZED_VIEW
+POSTHOOK: Input: default@customer
+POSTHOOK: Input: default@dates
+POSTHOOK: Input: default@lineorder
+POSTHOOK: Input: default@ssb_part
+POSTHOOK: Input: default@supplier
+POSTHOOK: Output: database:default
+POSTHOOK: Output: default@ssb_mv
+PREHOOK: query: explain
+select
+ sum(lo_extendedprice*lo_discount) as revenue
+from
+ lineorder, dates
+where
+ lo_orderdate = d_datekey
+ and d_year = 1993
+ and lo_discount between 1 and 3
+ and lo_quantity < 25
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ sum(lo_extendedprice*lo_discount) as revenue
+from
+ lineorder, dates
+where
+ lo_orderdate = d_datekey
+ and d_year = 1993
+ and lo_discount between 1 and 3
+ and lo_quantity < 25
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-0 depends on stages: Stage-1
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: ((d_year = 1993) and (lo_quantity < 25.0) and lo_discount BETWEEN 1.0 AND 3.0) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: discounted_price (type: double)
+ outputColumnNames: discounted_price
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(discounted_price)
+ 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: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ mode: mergepartial
+ outputColumnNames: _col0
+ Statistics: Num rows: 1 Data size: 8 Basic stats: COMPLETE Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 8 Basic stats: COMPLETE Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ sum(lo_extendedprice*lo_discount) as revenue
+from
+ lineorder, dates
+where
+ lo_orderdate = d_datekey
+ and d_yearmonthnum = 199401
+ and lo_discount between 4 and 6
+ and lo_quantity between 26 and 35
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ sum(lo_extendedprice*lo_discount) as revenue
+from
+ lineorder, dates
+where
+ lo_orderdate = d_datekey
+ and d_yearmonthnum = 199401
+ and lo_discount between 4 and 6
+ and lo_quantity between 26 and 35
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-0 depends on stages: Stage-1
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: ((d_yearmonthnum = 199401) and lo_discount BETWEEN 4.0 AND 6.0 and lo_quantity BETWEEN 26.0 AND 35.0) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: discounted_price (type: double)
+ outputColumnNames: discounted_price
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(discounted_price)
+ 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: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ mode: mergepartial
+ outputColumnNames: _col0
+ Statistics: Num rows: 1 Data size: 8 Basic stats: COMPLETE Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 8 Basic stats: COMPLETE Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ sum(lo_extendedprice*lo_discount) as revenue
+from
+ lineorder, dates
+where
+ lo_orderdate = d_datekey
+ and d_weeknuminyear = 6
+ and d_year = 1994
+ and lo_discount between 5 and 7
+ and lo_quantity between 26 and 35
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ sum(lo_extendedprice*lo_discount) as revenue
+from
+ lineorder, dates
+where
+ lo_orderdate = d_datekey
+ and d_weeknuminyear = 6
+ and d_year = 1994
+ and lo_discount between 5 and 7
+ and lo_quantity between 26 and 35
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-0 depends on stages: Stage-1
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: ((d_weeknuminyear = 6) and (d_year = 1994) and lo_discount BETWEEN 5.0 AND 7.0 and lo_quantity BETWEEN 26.0 AND 35.0) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: discounted_price (type: double)
+ outputColumnNames: discounted_price
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(discounted_price)
+ 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: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ mode: mergepartial
+ outputColumnNames: _col0
+ Statistics: Num rows: 1 Data size: 8 Basic stats: COMPLETE Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 8 Basic stats: COMPLETE Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ sum(lo_revenue) as lo_revenue, d_year, p_brand1
+from
+ lineorder, dates, ssb_part, supplier
+where
+ lo_orderdate = d_datekey
+ and lo_partkey = p_partkey
+ and lo_suppkey = s_suppkey
+ and p_category = 'MFGR#12'
+ and s_region = 'AMERICA'
+group by
+ d_year, p_brand1
+order by
+ d_year, p_brand1
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ sum(lo_revenue) as lo_revenue, d_year, p_brand1
+from
+ lineorder, dates, ssb_part, supplier
+where
+ lo_orderdate = d_datekey
+ and lo_partkey = p_partkey
+ and lo_suppkey = s_suppkey
+ and p_category = 'MFGR#12'
+ and s_region = 'AMERICA'
+group by
+ d_year, p_brand1
+order by
+ d_year, p_brand1
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: ((p_category = 'MFGR#12') and (s_region = 'AMERICA')) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: d_year (type: int), p_brand1 (type: string), lo_revenue (type: double)
+ outputColumnNames: d_year, p_brand1, lo_revenue
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(lo_revenue)
+ keys: d_year (type: int), p_brand1 (type: string)
+ mode: hash
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string)
+ sort order: ++
+ Map-reduce partition columns: _col0 (type: int), _col1 (type: string)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col2 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int), KEY._col1 (type: string)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: _col2 (type: double), _col0 (type: int), _col1 (type: string)
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col1 (type: int), _col2 (type: string)
+ sort order: ++
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col0 (type: double)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: VALUE._col0 (type: double), KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: string)
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ sum(lo_revenue) as lo_revenue, d_year, p_brand1
+from
+ lineorder, dates, ssb_part, supplier
+where
+ lo_orderdate = d_datekey
+ and lo_partkey = p_partkey
+ and lo_suppkey = s_suppkey
+ and p_brand1 between 'MFGR#2221' and 'MFGR#2228'
+ and s_region = 'ASIA'
+group by
+ d_year, p_brand1
+order by
+ d_year, p_brand1
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ sum(lo_revenue) as lo_revenue, d_year, p_brand1
+from
+ lineorder, dates, ssb_part, supplier
+where
+ lo_orderdate = d_datekey
+ and lo_partkey = p_partkey
+ and lo_suppkey = s_suppkey
+ and p_brand1 between 'MFGR#2221' and 'MFGR#2228'
+ and s_region = 'ASIA'
+group by
+ d_year, p_brand1
+order by
+ d_year, p_brand1
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: ((s_region = 'ASIA') and p_brand1 BETWEEN 'MFGR#2221' AND 'MFGR#2228') (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: d_year (type: int), p_brand1 (type: string), lo_revenue (type: double)
+ outputColumnNames: d_year, p_brand1, lo_revenue
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(lo_revenue)
+ keys: d_year (type: int), p_brand1 (type: string)
+ mode: hash
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string)
+ sort order: ++
+ Map-reduce partition columns: _col0 (type: int), _col1 (type: string)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col2 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int), KEY._col1 (type: string)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: _col2 (type: double), _col0 (type: int), _col1 (type: string)
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col1 (type: int), _col2 (type: string)
+ sort order: ++
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col0 (type: double)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: VALUE._col0 (type: double), KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: string)
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ sum(lo_revenue) as lo_revenue, d_year, p_brand1
+from
+ lineorder, dates, ssb_part, supplier
+where
+ lo_orderdate = d_datekey
+ and lo_partkey = p_partkey
+ and lo_suppkey = s_suppkey
+ and p_brand1 = 'MFGR#2239'
+ and s_region = 'EUROPE'
+group by
+ d_year, p_brand1
+order by
+ d_year, p_brand1
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ sum(lo_revenue) as lo_revenue, d_year, p_brand1
+from
+ lineorder, dates, ssb_part, supplier
+where
+ lo_orderdate = d_datekey
+ and lo_partkey = p_partkey
+ and lo_suppkey = s_suppkey
+ and p_brand1 = 'MFGR#2239'
+ and s_region = 'EUROPE'
+group by
+ d_year, p_brand1
+order by
+ d_year, p_brand1
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: ((p_brand1 = 'MFGR#2239') and (s_region = 'EUROPE')) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: d_year (type: int), lo_revenue (type: double)
+ outputColumnNames: d_year, lo_revenue
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(lo_revenue)
+ keys: d_year (type: int)
+ mode: hash
+ outputColumnNames: _col0, _col1
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int)
+ sort order: +
+ Map-reduce partition columns: _col0 (type: int)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col1 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: _col1 (type: double), _col0 (type: int)
+ outputColumnNames: _col0, _col1
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col1 (type: int)
+ sort order: +
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col0 (type: double)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: VALUE._col0 (type: double), KEY.reducesinkkey0 (type: int), 'MFGR#2239' (type: string)
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ c_nation, s_nation, d_year,
+ sum(lo_revenue) as lo_revenue
+from
+ customer, lineorder, supplier, dates
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_orderdate = d_datekey
+ and c_region = 'ASIA'
+ and s_region = 'ASIA'
+ and d_year >= 1992 and d_year <= 1997
+group by
+ c_nation, s_nation, d_year
+order by
+ d_year asc, lo_revenue desc
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ c_nation, s_nation, d_year,
+ sum(lo_revenue) as lo_revenue
+from
+ customer, lineorder, supplier, dates
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_orderdate = d_datekey
+ and c_region = 'ASIA'
+ and s_region = 'ASIA'
+ and d_year >= 1992 and d_year <= 1997
+group by
+ c_nation, s_nation, d_year
+order by
+ d_year asc, lo_revenue desc
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: ((c_region = 'ASIA') and (d_year <= 1997) and (d_year >= 1992) and (s_region = 'ASIA')) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: c_nation (type: string), d_year (type: int), s_nation (type: string), lo_revenue (type: double)
+ outputColumnNames: c_nation, d_year, s_nation, lo_revenue
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(lo_revenue)
+ keys: d_year (type: int), c_nation (type: string), s_nation (type: string)
+ mode: hash
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ sort order: +++
+ Map-reduce partition columns: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col3 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int), KEY._col1 (type: string), KEY._col2 (type: string)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: _col1 (type: string), _col2 (type: string), _col0 (type: int), _col3 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col2 (type: int), _col3 (type: double)
+ sort order: +-
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col0 (type: string), _col1 (type: string)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: VALUE._col0 (type: string), VALUE._col1 (type: string), KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ c_city, s_city, d_year, sum(lo_revenue) as lo_revenue
+from
+ customer, lineorder, supplier, dates
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_orderdate = d_datekey
+ and c_nation = 'UNITED STATES'
+ and s_nation = 'UNITED STATES'
+ and d_year >= 1992 and d_year <= 1997
+group by
+ c_city, s_city, d_year
+order by
+ d_year asc, lo_revenue desc
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ c_city, s_city, d_year, sum(lo_revenue) as lo_revenue
+from
+ customer, lineorder, supplier, dates
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_orderdate = d_datekey
+ and c_nation = 'UNITED STATES'
+ and s_nation = 'UNITED STATES'
+ and d_year >= 1992 and d_year <= 1997
+group by
+ c_city, s_city, d_year
+order by
+ d_year asc, lo_revenue desc
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: ((c_nation = 'UNITED STATES') and (d_year <= 1997) and (d_year >= 1992) and (s_nation = 'UNITED STATES')) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: c_city (type: string), d_year (type: int), s_city (type: string), lo_revenue (type: double)
+ outputColumnNames: c_city, d_year, s_city, lo_revenue
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(lo_revenue)
+ keys: d_year (type: int), c_city (type: string), s_city (type: string)
+ mode: hash
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ sort order: +++
+ Map-reduce partition columns: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col3 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int), KEY._col1 (type: string), KEY._col2 (type: string)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: _col1 (type: string), _col2 (type: string), _col0 (type: int), _col3 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col2 (type: int), _col3 (type: double)
+ sort order: +-
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col0 (type: string), _col1 (type: string)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: VALUE._col0 (type: string), VALUE._col1 (type: string), KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ c_city, s_city, d_year, sum(lo_revenue) as lo_revenue
+from
+ customer, lineorder, supplier, dates
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_orderdate = d_datekey
+ and (c_city='UNITED KI1' or c_city='UNITED KI5')
+ and (s_city='UNITED KI1' or s_city='UNITED KI5')
+ and d_year >= 1992 and d_year <= 1997
+group by
+ c_city, s_city, d_year
+order by
+ d_year asc, lo_revenue desc
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ c_city, s_city, d_year, sum(lo_revenue) as lo_revenue
+from
+ customer, lineorder, supplier, dates
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_orderdate = d_datekey
+ and (c_city='UNITED KI1' or c_city='UNITED KI5')
+ and (s_city='UNITED KI1' or s_city='UNITED KI5')
+ and d_year >= 1992 and d_year <= 1997
+group by
+ c_city, s_city, d_year
+order by
+ d_year asc, lo_revenue desc
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: (((c_city = 'UNITED KI1') or (c_city = 'UNITED KI5')) and ((s_city = 'UNITED KI1') or (s_city = 'UNITED KI5')) and (d_year <= 1997) and (d_year >= 1992)) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(lo_revenue)
+ keys: d_year (type: int), c_city (type: string), s_city (type: string)
+ mode: hash
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ sort order: +++
+ Map-reduce partition columns: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col3 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int), KEY._col1 (type: string), KEY._col2 (type: string)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: _col1 (type: string), _col2 (type: string), _col0 (type: int), _col3 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col2 (type: int), _col3 (type: double)
+ sort order: +-
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col0 (type: string), _col1 (type: string)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: VALUE._col0 (type: string), VALUE._col1 (type: string), KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ c_city, s_city, d_year, sum(lo_revenue) as lo_revenue
+from
+ customer, lineorder, supplier, dates
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_orderdate = d_datekey
+ and (c_city='UNITED KI1' or c_city='UNITED KI5')
+ and (s_city='UNITED KI1' or s_city='UNITED KI5')
+ and d_yearmonth = 'Dec1997'
+group by
+ c_city, s_city, d_year
+order by
+ d_year asc, lo_revenue desc
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ c_city, s_city, d_year, sum(lo_revenue) as lo_revenue
+from
+ customer, lineorder, supplier, dates
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_orderdate = d_datekey
+ and (c_city='UNITED KI1' or c_city='UNITED KI5')
+ and (s_city='UNITED KI1' or s_city='UNITED KI5')
+ and d_yearmonth = 'Dec1997'
+group by
+ c_city, s_city, d_year
+order by
+ d_year asc, lo_revenue desc
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: (((c_city = 'UNITED KI1') or (c_city = 'UNITED KI5')) and ((s_city = 'UNITED KI1') or (s_city = 'UNITED KI5')) and (d_yearmonth = 'Dec1997')) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: c_city (type: string), d_year (type: int), s_city (type: string), lo_revenue (type: double)
+ outputColumnNames: c_city, d_year, s_city, lo_revenue
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(lo_revenue)
+ keys: d_year (type: int), c_city (type: string), s_city (type: string)
+ mode: hash
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ sort order: +++
+ Map-reduce partition columns: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col3 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int), KEY._col1 (type: string), KEY._col2 (type: string)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: _col1 (type: string), _col2 (type: string), _col0 (type: int), _col3 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col2 (type: int), _col3 (type: double)
+ sort order: +-
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col0 (type: string), _col1 (type: string)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: VALUE._col0 (type: string), VALUE._col1 (type: string), KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ d_year, c_nation,
+ sum(lo_revenue - lo_supplycost) as profit
+from
+ dates, customer, supplier, ssb_part, lineorder
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_partkey = p_partkey
+ and lo_orderdate = d_datekey
+ and c_region = 'AMERICA'
+ and s_region = 'AMERICA'
+ and (p_mfgr = 'MFGR#1' or p_mfgr = 'MFGR#2')
+group by
+ d_year, c_nation
+order by
+ d_year, c_nation
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ d_year, c_nation,
+ sum(lo_revenue - lo_supplycost) as profit
+from
+ dates, customer, supplier, ssb_part, lineorder
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_partkey = p_partkey
+ and lo_orderdate = d_datekey
+ and c_region = 'AMERICA'
+ and s_region = 'AMERICA'
+ and (p_mfgr = 'MFGR#1' or p_mfgr = 'MFGR#2')
+group by
+ d_year, c_nation
+order by
+ d_year, c_nation
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: (((p_mfgr = 'MFGR#1') or (p_mfgr = 'MFGR#2')) and (c_region = 'AMERICA') and (s_region = 'AMERICA')) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: c_nation (type: string), d_year (type: int), net_revenue (type: double)
+ outputColumnNames: c_nation, d_year, net_revenue
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(net_revenue)
+ keys: d_year (type: int), c_nation (type: string)
+ mode: hash
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string)
+ sort order: ++
+ Map-reduce partition columns: _col0 (type: int), _col1 (type: string)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col2 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int), KEY._col1 (type: string)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string)
+ sort order: ++
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col2 (type: double)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: string), VALUE._col0 (type: double)
+ outputColumnNames: _col0, _col1, _col2
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ d_year, s_nation, p_category,
+ sum(lo_revenue - lo_supplycost) as profit
+from
+ dates, customer, supplier, ssb_part, lineorder
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_partkey = p_partkey
+ and lo_orderdate = d_datekey
+ and c_region = 'AMERICA'
+ and s_region = 'AMERICA'
+ and (d_year = 1997 or d_year = 1998)
+ and (p_mfgr = 'MFGR#1' or p_mfgr = 'MFGR#2')
+group by
+ d_year, s_nation, p_category
+order by
+ d_year, s_nation, p_category
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ d_year, s_nation, p_category,
+ sum(lo_revenue - lo_supplycost) as profit
+from
+ dates, customer, supplier, ssb_part, lineorder
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_partkey = p_partkey
+ and lo_orderdate = d_datekey
+ and c_region = 'AMERICA'
+ and s_region = 'AMERICA'
+ and (d_year = 1997 or d_year = 1998)
+ and (p_mfgr = 'MFGR#1' or p_mfgr = 'MFGR#2')
+group by
+ d_year, s_nation, p_category
+order by
+ d_year, s_nation, p_category
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: (((d_year = 1997) or (d_year = 1998)) and ((p_mfgr = 'MFGR#1') or (p_mfgr = 'MFGR#2')) and (c_region = 'AMERICA') and (s_region = 'AMERICA')) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: d_year (type: int), p_category (type: string), s_nation (type: string), net_revenue (type: double)
+ outputColumnNames: d_year, p_category, s_nation, net_revenue
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(net_revenue)
+ keys: d_year (type: int), s_nation (type: string), p_category (type: string)
+ mode: hash
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ sort order: +++
+ Map-reduce partition columns: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col3 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int), KEY._col1 (type: string), KEY._col2 (type: string)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ sort order: +++
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col3 (type: double)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: string), KEY.reducesinkkey2 (type: string), VALUE._col0 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: explain
+select
+ d_year, s_city, p_brand1,
+ sum(lo_revenue - lo_supplycost) as profit
+from
+ dates, customer, supplier, ssb_part, lineorder
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_partkey = p_partkey
+ and lo_orderdate = d_datekey
+ and c_region = 'AMERICA'
+ and s_nation = 'UNITED STATES'
+ and (d_year = 1997 or d_year = 1998)
+ and p_category = 'MFGR#14'
+group by
+ d_year, s_city, p_brand1
+order by
+ d_year, s_city, p_brand1
+PREHOOK: type: QUERY
+POSTHOOK: query: explain
+select
+ d_year, s_city, p_brand1,
+ sum(lo_revenue - lo_supplycost) as profit
+from
+ dates, customer, supplier, ssb_part, lineorder
+where
+ lo_custkey = c_custkey
+ and lo_suppkey = s_suppkey
+ and lo_partkey = p_partkey
+ and lo_orderdate = d_datekey
+ and c_region = 'AMERICA'
+ and s_nation = 'UNITED STATES'
+ and (d_year = 1997 or d_year = 1998)
+ and p_category = 'MFGR#14'
+group by
+ d_year, s_city, p_brand1
+order by
+ d_year, s_city, p_brand1
+POSTHOOK: type: QUERY
+STAGE DEPENDENCIES:
+ Stage-1 is a root stage
+ Stage-2 depends on stages: Stage-1
+ Stage-0 depends on stages: Stage-2
+
+STAGE PLANS:
+ Stage: Stage-1
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ alias: default.ssb_mv
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Filter Operator
+ predicate: (((d_year = 1997) or (d_year = 1998)) and (c_region = 'AMERICA') and (p_category = 'MFGR#14') and (s_nation = 'UNITED STATES')) (type: boolean)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Select Operator
+ expressions: d_year (type: int), p_brand1 (type: string), s_city (type: string), net_revenue (type: double)
+ outputColumnNames: d_year, p_brand1, s_city, net_revenue
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Group By Operator
+ aggregations: sum(net_revenue)
+ keys: d_year (type: int), s_city (type: string), p_brand1 (type: string)
+ mode: hash
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ sort order: +++
+ Map-reduce partition columns: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col3 (type: double)
+ Reduce Operator Tree:
+ Group By Operator
+ aggregations: sum(VALUE._col0)
+ keys: KEY._col0 (type: int), KEY._col1 (type: string), KEY._col2 (type: string)
+ mode: mergepartial
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazybinary.LazyBinarySerDe
+
+ Stage: Stage-2
+ Map Reduce
+ Map Operator Tree:
+ TableScan
+ Reduce Output Operator
+ key expressions: _col0 (type: int), _col1 (type: string), _col2 (type: string)
+ sort order: +++
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ value expressions: _col3 (type: double)
+ Reduce Operator Tree:
+ Select Operator
+ expressions: KEY.reducesinkkey0 (type: int), KEY.reducesinkkey1 (type: string), KEY.reducesinkkey2 (type: string), VALUE._col0 (type: double)
+ outputColumnNames: _col0, _col1, _col2, _col3
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ File Output Operator
+ compressed: false
+ Statistics: Num rows: 1 Data size: 0 Basic stats: PARTIAL Column stats: NONE
+ table:
+ input format: org.apache.hadoop.mapred.SequenceFileInputFormat
+ output format: org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat
+ serde: org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
+
+ Stage: Stage-0
+ Fetch Operator
+ limit: -1
+ Processor Tree:
+ ListSink
+
+PREHOOK: query: DROP MATERIALIZED VIEW `ssb_mv`
+PREHOOK: type: DROP_MATERIALIZED_VIEW
+PREHOOK: Input: default@ssb_mv
+PREHOOK: Output: default@ssb_mv
+POSTHOOK: query: DROP MATERIALIZED VIEW `ssb_mv`
+POSTHOOK: type: DROP_MATERIALIZED_VIEW
+POSTHOOK: Input: default@ssb_mv
+POSTHOOK: Output: default@ssb_mv