You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by "Janaki Lahorani (JIRA)" <ji...@apache.org> on 2018/04/10 22:41:00 UTC

[jira] [Created] (HIVE-19160) Insert data into decimal column fails with Null Pointer Exception

Janaki Lahorani created HIVE-19160:
--------------------------------------

             Summary: Insert data into decimal column fails with Null Pointer Exception
                 Key: HIVE-19160
                 URL: https://issues.apache.org/jira/browse/HIVE-19160
             Project: Hive
          Issue Type: Bug
            Reporter: Janaki Lahorani
            Assignee: Janaki Lahorani


drop table if exists testDecimal;
create table testDecimal
(cId        TINYINT,
 cBigInt    DECIMAL,
 cInt       DECIMAL,
 cSmallInt  DECIMAL,
 cTinyint   DECIMAL);

insert into testDecimal values
(1,
 1234567890123456789,
 1234567890,
 12345,
 123);

insert into testDecimal values
(2,
 1,
 2,
 3,
 4);

The second insert fails with null pointer exception.

2018-04-10T15:23:23,080 ERROR [5dba40ef-be49-4187-8a72-afbb46c41ecc main] metastore.RetryingHMSHandler: java.lang.NullPointerException
	at org.apache.hadoop.hive.metastore.api.Decimal.compareTo(Decimal.java:318)
	at org.apache.hadoop.hive.metastore.columnstats.merge.DecimalColumnStatsMerger.merge(DecimalColumnStatsMerger.java:35)
	at org.apache.hadoop.hive.metastore.utils.MetaStoreUtils.mergeColStats(MetaStoreUtils.java:1040)
	at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.set_aggr_stats_for(HiveMetaStore.java:7166)
	at sun.reflect.GeneratedMethodAccessor43.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.apache.hadoop.hive.metastore.RetryingHMSHandler.invokeInternal(RetryingHMSHandler.java:147)
	at org.apache.hadoop.hive.metastore.RetryingHMSHandler.invoke(RetryingHMSHandler.java:108)
	at com.sun.proxy.$Proxy40.set_aggr_stats_for(Unknown Source)
	at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.setPartitionColumnStatistics(HiveMetaStoreClient.java:1870)
	at org.apache.hadoop.hive.ql.metadata.SessionHiveMetaStoreClient.setPartitionColumnStatistics(SessionHiveMetaStoreClient.java:395)
	at sun.reflect.GeneratedMethodAccessor42.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.apache.hadoop.hive.metastore.RetryingMetaStoreClient.invoke(RetryingMetaStoreClient.java:212)
	at com.sun.proxy.$Proxy41.setPartitionColumnStatistics(Unknown Source)
	at org.apache.hadoop.hive.ql.metadata.Hive.setPartitionColumnStatistics(Hive.java:4171)
	at org.apache.hadoop.hive.ql.stats.ColStatsProcessor.persistColumnStats(ColStatsProcessor.java:179)
	at org.apache.hadoop.hive.ql.stats.ColStatsProcessor.process(ColStatsProcessor.java:83)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)