hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pengcheng Xiong (JIRA)" <>
Subject [jira] [Commented] (HIVE-10833) RowResolver looks mangled with CBO
Date Wed, 27 May 2015 21:18:23 GMT


Pengcheng Xiong commented on HIVE-10833:

[~ekoifman], could you try again on the latest trunk? I was not able to reproduce it.
with CBO enabled, the first time I run insert and I put a break point at   _selectStar 
(currently 3865) and examine _out_rwsch.rslvMap
values__tmp__table__1{(tmp_values_col1,_col0: string)(tmp_values_col2,_col1: string)} 
The query failed, but I did see "values__tmp__table__1" rather than null.
FAILED: NullPointerException null
If I run the same insert again, I will see
values__tmp__table__2{(tmp_values_col1,_col0: string)(tmp_values_col2,_col1: string)} 
I still can not see "null".

> RowResolver looks mangled with CBO 
> -----------------------------------
>                 Key: HIVE-10833
>                 URL:
>             Project: Hive
>          Issue Type: Bug
>          Components: CBO, Query Planning
>    Affects Versions: 1.3.0
>            Reporter: Eugene Koifman
>            Assignee: Pengcheng Xiong
> While working on HIVE-10828 I noticed that internal state of RowResolver looks odd when
CBO is enabled.
> Consider the script below.
> {noformat}
> set hive.enforce.bucketing=true;
> set hive.exec.dynamic.partition.mode=nonstrict;
> set hive.cbo.enable=false;
> drop table if exists acid_partitioned;
> create table acid_partitioned (a int, c string)
>   partitioned by (p int)
>   clustered by (a) into 1 buckets;
> insert into acid_partitioned partition (p) (a,p) values(1,1);
> {noformat}
> (this test is part of ql/src/test/results/clientpositive/insert_into_with_schema2.q)
> With CBO on,
> if you put a break point in {noformat}SemanticAnalyzer.genSelectPlan(String dest, ASTNode
selExprList, QB qb, Operator<?> input,
>       Operator<?> inputForSelectStar, boolean outerLV){noformat} at line 
>     _selectStar = selectStar && exprList.getChildCount() == posn + 1;_
> (currently 3865) and examine _out_rwsch.rslvMap_ variable looks like {noformat}{null={values__tmp__table__1.tmp_values_col1=_col0:
string, values__tmp__table__1.tmp_values_col2=_col1: string}}{noformat}
> with CBO disabled, the same _out_rwsch.rslvMap_ looks like
> {noformat}{values__tmp__table__1={tmp_values_col1=_col0: string, tmp_values_col2=_col1:
> The _out_rwsch.invRslvMap_ also differs in the same way.
> It seems that the version you get with CBO off is the correct one since
> _insert into acid_partitioned partition (p) (a,p) values(1,1)_ is rewritten to
> _insert into acid_partitioned partition (p) (a,p) select * from values__tmp__table__1_
> CC [~ashutoshc]

This message was sent by Atlassian JIRA

View raw message