[
https://issues.apache.org/jira/browse/HIVE-22274?focusedWorklogId=328657&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-328657
]
ASF GitHub Bot logged work on HIVE-22274:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 15/Oct/19 16:09
Start Date: 15/Oct/19 16:09
Worklog Time Spent: 10m
Work Description: scarlin-cloudera commented on pull request #809:
HIVE-22274: upgrade Calcite to 1.21
URL: https://github.com/apache/hive/pull/809#discussion_r335046695
##########
File path: ql/src/test/results/clientpositive/concat_op.q.out
##########
@@ -311,7 +311,7 @@ POSTHOOK: query: explain formatted select key || value
from src
POSTHOOK: type: QUERY
POSTHOOK: Input: default@src
#### A masked pattern was here ####
-{"CBOPlan":"{\n \"rels\": [\n {\n \"id\": \"0\",\n \"relOp\":
\"org.apache.hadoop.hive.ql.optimizer.calcite.reloperators.HiveTableScan\",\n
\"table\": [\n \"default\",\n \"src\"\n ],\n
\"table:alias\": \"src\",\n \"inputs\": [],\n \"rowCount\": 500.0,\n
\"avgRowSize\": 9.624,\n \"rowType\": [\n {\n
\"type\": \"VARCHAR\",\n \"nullable\": true,\n \"precision\":
2147483647,\n \"name\": \"key\"\n },\n {\n
\"type\": \"VARCHAR\",\n \"nullable\": true,\n \"precision\":
2147483647,\n \"name\": \"value\"\n },\n {\n
\"type\": \"BIGINT\",\n \"nullable\": true,\n \"name\":
\"BLOCK__OFFSET__INSIDE__FILE\"\n },\n {\n \"type\":
\"VARCHAR\",\n \"nullable\": true,\n \"precision\":
2147483647,\n \"name\": \"INPUT__FILE__NAME\"\n },\n {\n
\"fields\": [\n {\n \"type\": \"BIGINT\",\n
\"nullable\": true,\n \"name\": \"writeid\"\n
},\n {\n \"type\": \"INTEGER\",\n
\"nullable\": true,\n \"name\": \"bucketid\"\n },\n
{\n \"type\": \"BIGINT\",\n \"nullable\":
true,\n \"name\": \"rowid\"\n }\n ],\n
\"name\": \"ROW__ID\"\n }\n ],\n \"colStats\": [\n {\n
\"name\": \"key\",\n \"ndv\": 316\n },\n {\n
\"name\": \"value\",\n \"ndv\": 307\n }\n ]\n
},\n {\n \"id\": \"1\",\n \"relOp\":
\"org.apache.hadoop.hive.ql.optimizer.calcite.reloperators.HiveProject\",\n
\"fields\": [\n \"_o__c0\"\n ],\n \"exprs\": [\n {\n
\"op\": \"||\",\n \"operands\": [\n {\n
\"input\": 0,\n \"name\": \"$0\"\n },\n {\n
\"input\": 1,\n \"name\": \"$1\"\n }\n
]\n }\n ],\n \"rowCount\": 500.0\n }\n
]\n}","optimizedSQL":"SELECT `key` || `value` AS `_o__c0`\nFROM
`default`.`src`","cboInfo":"Plan optimized by CBO.","STAGE
DEPENDENCIES":{"Stage-1":{"ROOT STAGE":"TRUE"},"Stage-0":{"DEPENDENT
STAGES":"Stage-1"}},"STAGE PLANS":{"Stage-1":{"Map Reduce":{"Map Operator
Tree:":[{"TableScan":{"alias:":"src","columns:":["key","value"],"database:":"default","Statistics:":"Num
rows: 500 Data size: 89000 Basic stats: COMPLETE Column stats:
COMPLETE","table:":"src","isTempTable:":"false","OperatorId:":"TS_0","children":{"Select
Operator":{"expressions:":"concat(key, value) (type:
string)","columnExprMap:":{"_col0":"concat(key,
value)"},"outputColumnNames:":["_col0"],"Statistics:":"Num rows: 500 Data size:
92000 Basic stats: COMPLETE Column stats:
COMPLETE","OperatorId:":"SEL_3","children":{"File Output
Operator":{"compressed:":"false","Statistics:":"Num rows: 500 Data size: 92000
Basic stats: COMPLETE Column stats: COMPLETE","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"},"OperatorId:":"FS_4"}}}}}}],"Execution
mode:":"vectorized"}},"Stage-0":{"Fetch Operator":{"limit:":"-1","Processor
Tree:":{"ListSink":{"OperatorId:":"LIST_SINK_5"}}}}}}
+{"CBOPlan":"{\n \"rels\": [\n {\n \"id\": \"0\",\n \"relOp\":
\"org.apache.hadoop.hive.ql.optimizer.calcite.reloperators.HiveTableScan\",\n
\"table\": [\n \"default\",\n \"src\"\n ],\n
\"table:alias\": \"src\",\n \"inputs\": [],\n \"rowCount\": 500.0,\n
\"avgRowSize\": 9.624,\n \"rowType\": [\n {\n
\"type\": \"VARCHAR\",\n \"nullable\": true,\n \"precision\":
2147483647,\n \"name\": \"key\"\n },\n {\n
\"type\": \"VARCHAR\",\n \"nullable\": true,\n \"precision\":
2147483647,\n \"name\": \"value\"\n },\n {\n
\"type\": \"BIGINT\",\n \"nullable\": true,\n \"name\":
\"BLOCK__OFFSET__INSIDE__FILE\"\n },\n {\n \"type\":
\"VARCHAR\",\n \"nullable\": true,\n \"precision\":
2147483647,\n \"name\": \"INPUT__FILE__NAME\"\n },\n {\n
\"fields\": [\n {\n \"type\": \"BIGINT\",\n
\"nullable\": true,\n \"name\": \"writeid\"\n
},\n {\n \"type\": \"INTEGER\",\n
\"nullable\": true,\n \"name\": \"bucketid\"\n },\n
{\n \"type\": \"BIGINT\",\n \"nullable\":
true,\n \"name\": \"rowid\"\n }\n ],\n
\"name\": \"ROW__ID\"\n }\n ],\n \"colStats\": [\n {\n
\"name\": \"key\",\n \"ndv\": 316\n },\n {\n
\"name\": \"value\",\n \"ndv\": 307\n }\n ]\n
},\n {\n \"id\": \"1\",\n \"relOp\":
\"org.apache.hadoop.hive.ql.optimizer.calcite.reloperators.HiveProject\",\n
\"fields\": [\n \"_o__c0\"\n ],\n \"exprs\": [\n {\n
\"op\": {\n \"name\": \"||\",\n \"kind\":
\"OTHER_FUNCTION\",\n \"syntax\": \"SPECIAL\"\n },\n
\"operands\": [\n {\n \"input\": 0,\n
\"name\": \"$0\"\n },\n {\n \"input\": 1,\n
\"name\": \"$1\"\n }\n ]\n }\n ],\n
\"rowCount\": 500.0\n }\n ]\n}","optimizedSQL":"SELECT `key` ||
`value` AS `_o__c0`\nFROM `default`.`src`","cboInfo":"Plan optimized by
CBO.","STAGE DEPENDENCIES":{"Stage-1":{"ROOT
STAGE":"TRUE"},"Stage-0":{"DEPENDENT STAGES":"Stage-1"}},"STAGE
PLANS":{"Stage-1":{"Map Reduce":{"Map Operator
Tree:":[{"TableScan":{"alias:":"src","columns:":["key","value"],"database:":"default","Statistics:":"Num
rows: 500 Data size: 89000 Basic stats: COMPLETE Column stats:
COMPLETE","table:":"src","isTempTable:":"false","OperatorId:":"TS_0","children":{"Select
Operator":{"expressions:":"concat(key, value) (type:
string)","columnExprMap:":{"_col0":"concat(key,
value)"},"outputColumnNames:":["_col0"],"Statistics:":"Num rows: 500 Data size:
92000 Basic stats: COMPLETE Column stats:
COMPLETE","OperatorId:":"SEL_3","children":{"File Output
Operator":{"compressed:":"false","Statistics:":"Num rows: 500 Data size: 92000
Basic stats: COMPLETE Column stats: COMPLETE","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"},"OperatorId:":"FS_4"}}}}}}],"Execution
mode:":"vectorized"}},"Stage-0":{"Fetch Operator":{"limit:":"-1","Processor
Tree:":{"ListSink":{"OperatorId:":"LIST_SINK_5"}}}}}}
Review comment:
I only looked at it briefly, but Calcite definitely made some changes in
their json.
Here, it looks like "op" contains a mapping (e.g. operands got pushed under
op as opposed to being on the same level). If you want, I'll hunt down the
Calcite Jira.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 328657)
Time Spent: 1h (was: 50m)
> Upgrade Calcite version to 1.21.0
> ---------------------------------
>
> Key: HIVE-22274
> URL: https://issues.apache.org/jira/browse/HIVE-22274
> Project: Hive
> Issue Type: Task
> Affects Versions: 3.1.2
> Reporter: Steve Carlin
> Assignee: Steve Carlin
> Priority: Major
> Labels: pull-request-available
> Attachments: HIVE-22274.1.patch, HIVE-22274.2.patch,
> HIVE-22274.3.patch, HIVE-22274.4.patch, HIVE-22274.5.patch,
> HIVE-22274.6.patch, HIVE-22274.7.patch, HIVE-22274.patch
>
> Time Spent: 1h
> Remaining Estimate: 0h
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)