[ 
https://issues.apache.org/jira/browse/HIVE-4057?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

binlijin updated HIVE-4057:
---------------------------

    Attachment: HIVE-4057.patch
    
> LazyHBaseRow may return cache data if the field is null and make the result 
> wrong
> ---------------------------------------------------------------------------------
>
>                 Key: HIVE-4057
>                 URL: https://issues.apache.org/jira/browse/HIVE-4057
>             Project: Hive
>          Issue Type: Bug
>          Components: HBase Handler
>    Affects Versions: 0.11.0
>            Reporter: binlijin
>         Attachments: HIVE-4057.patch
>
>
> LazyHBaseRow
> {code}
> private Object uncheckedGetField(int fieldID) {
>    if(!fieldsInited[fieldID]) {
>       fieldsInited[fieldID] = true;
>           byte [] res = result.getValue(colMap.familyNameBytes, 
> colMap.qualifierNameBytes);
>           if (res == null) {
>             return null;
>           }
>     }
>     return fields[fieldID].getObject();
> }
> {code}
> if there is a LazyHBaseRow instance row,  the fieldID is 0, we assume this 
> field is null, so the first time row.uncheckedGetField(0) will return null, 
> but the second time when row.uncheckedGetField(0) will return 
> fields[fieldID].getObject(), this is the last cache data.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to