[
https://issues.apache.org/jira/browse/DRILL-4868?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15746822#comment-15746822
]
ASF GitHub Bot commented on DRILL-4868:
---------------------------------------
GitHub user chunhui-shi opened a pull request:
https://github.com/apache/drill/pull/695
DRILL-4868: fix how hive function set DrillBuf.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/chunhui-shi/drill DRILL-4868
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/drill/pull/695.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #695
----
commit 54334558b63c4f15e66bbb88f639911d56e04cb9
Author: chunhui-shi <[email protected]>
Date: 2016-12-13T23:16:40Z
DRILL-4868: fix how hive function set DrillBuf.
----
> Hive functions should update writerIndex accordingly when return binary type
> ----------------------------------------------------------------------------
>
> Key: DRILL-4868
> URL: https://issues.apache.org/jira/browse/DRILL-4868
> Project: Apache Drill
> Issue Type: Bug
> Reporter: Chunhui Shi
> Assignee: Chunhui Shi
>
> unhex is a Hive function. the returned binary buffer could not be consumed by
> convert_from as shown below.
> 0: jdbc:drill:zk=10.10.88.128:5181> select
> convert_from(unhex('0a5f710b'),'int_be') from (values(1));
> Error: SYSTEM ERROR: IndexOutOfBoundsException: readerIndex(0) + length(4)
> exceeds writerIndex(0): DrillBuf[31], udle: [25 0..1024]
> Fragment 0:0
> [Error Id: 5e72ce4a-6164-4260-8317-ca2bb6325013 on atsqa4-128.qa.lab:31010]
> (state=,code=0)
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)