drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rahul Challapalli (JIRA)" <j...@apache.org>
Subject [jira] [Created] (DRILL-3299) Hive: hex function from hive returning non-printable characters
Date Tue, 16 Jun 2015 01:59:00 GMT
Rahul Challapalli created DRILL-3299:

             Summary: Hive: hex function from hive returning non-printable characters
                 Key: DRILL-3299
                 URL: https://issues.apache.org/jira/browse/DRILL-3299
             Project: Apache Drill
          Issue Type: Bug
          Components: Functions - Hive
            Reporter: Rahul Challapalli
            Assignee: Mehant Baid


The below query returns the data properly from sqlline. 
select hex(l_suppkey) from hive.tpch01_parquet_nodate.lineitem;

However when I use the below code to read it using JDBC, I am getting un-printable characters
resultSet = statement.executeQuery(query);
String str = new String(resultSet.getBytes(i));

When I create the string with UTF-16 encoding, things work fine
String str = new String(resultSet.getBytes(i), java.nio.charset.Charset.forName("UTF-16"))

Most likely there could be nothing wrong with drill and the clients could be resposible for
inspecting the types and reading the data accordingly.

Just wanted to raise this JIRA to verify whether the current behavior is expected or not.

This message was sent by Atlassian JIRA

View raw message