You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by "Gabriel Reid (JIRA)" <ji...@apache.org> on 2014/03/16 08:21:08 UTC

[jira] [Resolved] (PHOENIX-665) How to resolve the data type problem in phoenix?

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

Gabriel Reid resolved PHOENIX-665.
----------------------------------

    Resolution: Fixed

Bulk resolve of closed issues imported from GitHub. This status was reached by first re-opening all closed imported issues and then resolving them in bulk.

> How to resolve the data type problem in phoenix?
> ------------------------------------------------
>
>                 Key: PHOENIX-665
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-665
>             Project: Phoenix
>          Issue Type: Task
>            Reporter: liuziliang
>              Labels: question
>
> I have create a table via hive in hbase. When I insert integer data into the table, it can be retrieved by hive or hbase, but can not be retrieved correctly via phoenix, and the error is :
> java.lang.IllegalArgumentException: offset (715) + length (8) exceed the capacity of the array: 720
>         at org.apache.hadoop.hbase.util.Bytes.explainWrongLengthOrOffset(Bytes.java:543)
>         at org.apache.hadoop.hbase.util.Bytes.toLong(Bytes.java:521)
>         at org.apache.hadoop.hbase.util.Bytes.toDouble(Bytes.java:620)
>         at com.salesforce.phoenix.schema.PDataType$UnsignedDoubleCodec.decodeDouble(PDataType.java:4152)
>         at com.salesforce.phoenix.schema.PDataType$18.toObject(PDataType.java:2756)
>         at com.salesforce.phoenix.schema.PDataType.toObject(PDataType.java:4585)
>         at com.salesforce.phoenix.schema.PDataType.toObject(PDataType.java:4564)
>         at com.salesforce.phoenix.schema.PDataType.toObject(PDataType.java:4573)
>         at com.salesforce.phoenix.compile.ExpressionProjector.getValue(ExpressionProjector.java:85)
>         at com.salesforce.phoenix.jdbc.PhoenixResultSet.getObject(PhoenixResultSet.java:476)
>         at sqlline.SqlLine$Rows$Row.<init>(SqlLine.java:2314)
>         at sqlline.SqlLine$IncrementalRows.hasNext(SqlLine.java:2430)
>         at sqlline.SqlLine$TableOutputFormat.print(SqlLine.java:2074)
>         at sqlline.SqlLine.print(SqlLine.java:1735)
>         at sqlline.SqlLine$Commands.execute(SqlLine.java:3683)
>         at sqlline.SqlLine$Commands.sql(SqlLine.java:3584)
>         at sqlline.SqlLine.dispatch(SqlLine.java:821)
>         at sqlline.SqlLine.begin(SqlLine.java:699)
>         at sqlline.SqlLine.mainWithInputRedirection(SqlLine.java:441)
>         at sqlline.SqlLine.main(SqlLine.java:424)
> The data type in hive is integer and the data type in phoenix is unsigned_int.
> Also, if insert data by phoenix, it will be displayed correctly in phoenix but null in hive or hbase.
> How can I resolve this problem?
> Any help will be appreciated.



--
This message was sent by Atlassian JIRA
(v6.2#6252)