[ https://issues.apache.org/jira/browse/CARBONDATA-1059?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] SWATI RAO closed CARBONDATA-1059. --------------------------------- Resolution: Fixed > While executing Select Query getting an exception : "org.apache.hadoop.hive.ql.metadata.HiveException" > ------------------------------------------------------------------------------------------------------ > > Key: CARBONDATA-1059 > URL: https://issues.apache.org/jira/browse/CARBONDATA-1059 > Project: CarbonData > Issue Type: Bug > Affects Versions: 1.1.0 > Environment: SPARK1.6 > Reporter: SWATI RAO > Attachments: Test_Data1.csv, Test_Data1_h1.csv > > > CARBONDATA: > CREATE: > 0: jdbc:hive2://192.168.2.126:10000> create table Test_Boundary (c1_int int,c2_Bigint Bigint,c3_Decimal Decimal(38,30),c4_double double,c5_string string,c6_Timestamp Timestamp,c7_Datatype_Desc string) STORED BY 'org.apache.carbondata.format' > 0: jdbc:hive2://192.168.2.126:10000> ; > +---------+--+ > | Result | > +---------+--+ > +---------+--+ > No rows selected (0.28 seconds) > LOAD: > 0: jdbc:hive2://192.168.2.126:10000> LOAD DATA INPATH 'hdfs://localhost:54311/BabuStore/TestData/Data/Test_Data1.csv' INTO table Test_Boundary OPTIONS('DELIMITER'=',','QUOTECHAR'='','BAD_RECORDS_ACTION'='FORCE','FILEHEADER'=''); > +---------+--+ > | Result | > +---------+--+ > +---------+--+ > No rows selected (1.912 seconds) > SELECT : > 0: jdbc:hive2://192.168.2.126:10000> select min(c1_int),max(c1_int),sum(c1_int),avg(c1_int) , count(c1_int), variance(c1_int) from Test_Boundary where rand(c1_int)=0.6201007799387834 or rand(c1_int)=0.45540022789662593 > 0: jdbc:hive2://192.168.2.126:10000> ; > Error: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 20.0 failed 1 times, most recent failure: Lost task 0.0 in stage 20.0 (TID 21, localhost): org.apache.hadoop.hive.ql.metadata.HiveException: Unable to execute method public org.apache.hadoop.hive.serde2.io.DoubleWritable org.apache.hadoop.hive.ql.udf.UDFRand.evaluate(org.apache.hadoop.io.LongWritable) on object org.apache.hadoop.hive.ql.udf.UDFRand@160c41fd of class org.apache.hadoop.hive.ql.udf.UDFRand with arguments {null} of size 1 > at org.apache.hadoop.hive.ql.exec.FunctionRegistry.invoke(FunctionRegistry.java:981) > at org.apache.spark.sql.hive.HiveSimpleUDF.eval(hiveUDFs.scala:185) > at org.apache.spark.sql.catalyst.expressions.GeneratedClass$SpecificPredicate.eval(Unknown Source) > at org.apache.spark.sql.catalyst.expressions.codegen.GeneratePredicate$$anonfun$create$2.apply(GeneratePredicate.scala:68) > at org.apache.spark.sql.catalyst.expressions.codegen.GeneratePredicate$$anonfun$create$2.apply(GeneratePredicate.scala:68) > at org.apache.spark.sql.execution.Filter$$anonfun$2$$anonfun$apply$2.apply(basicOperators.scala:74) > at org.apache.spark.sql.execution.Filter$$anonfun$2$$anonfun$apply$2.apply(basicOperators.scala:72) > at scala.collection.Iterator$$anon$14.hasNext(Iterator.scala:390) > at scala.collection.Iterator$$anon$11.hasNext(Iterator.scala:327) > at org.apache.spark.sql.execution.aggregate.TungstenAggregationIterator.processInputs(TungstenAggregationIterator.scala:504) > at org.apache.spark.sql.execution.aggregate.TungstenAggregationIterator.<init>(TungstenAggregationIterator.scala:686) > at org.apache.spark.sql.execution.aggregate.TungstenAggregate$$anonfun$doExecute$1$$anonfun$2.apply(TungstenAggregate.scala:95) > at org.apache.spark.sql.execution.aggregate.TungstenAggregate$$anonfun$doExecute$1$$anonfun$2.apply(TungstenAggregate.scala:86) > at org.apache.spark.rdd.RDD$$anonfun$mapPartitions$1$$anonfun$apply$20.apply(RDD.scala:710) > at org.apache.spark.rdd.RDD$$anonfun$mapPartitions$1$$anonfun$apply$20.apply(RDD.scala:710) > at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:38) > at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:306) > at org.apache.spark.rdd.RDD.iterator(RDD.scala:270) > at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:38) > at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:306) > at org.apache.spark.rdd.RDD.iterator(RDD.scala:270) > at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:73) > at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) > at org.apache.spark.scheduler.Task.run(Task.scala:89) > at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:227) > at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) > at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) > at java.lang.Thread.run(Thread.java:745) > Caused by: java.lang.reflect.InvocationTargetException > at sun.reflect.GeneratedMethodAccessor72.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.ql.exec.FunctionRegistry.invoke(FunctionRegistry.java:957) > ... 27 more > Caused by: java.lang.NullPointerException > at org.apache.hadoop.hive.ql.udf.UDFRand.evaluate(UDFRand.java:57) > ... 31 more > Driver stacktrace: (state=,code=0) > HIVE: > CREATE : > 0: jdbc:hive2://192.168.2.126:10000> create table Test_Boundary_h1 (c1_int int,c2_Bigint Bigint,c3_Decimal Decimal(38,30),c4_double double,c5_string string,c6_Timestamp Timestamp,c7_Datatype_Desc string) ROW FORMAT DELIMITED FIELDS TERMINATED BY ',' > 0: jdbc:hive2://192.168.2.126:10000> ; > +---------+--+ > | result | > +---------+--+ > +---------+--+ > No rows selected (0.524 seconds) > LOAD : > 0: jdbc:hive2://192.168.2.126:10000> load data local inpath '/opt/Carbon/CarbonData/TestData/Data/Test_Data1_h1.csv' OVERWRITE INTO TABLE Test_Boundary_h1 > 0: jdbc:hive2://192.168.2.126:10000> ; > +---------+--+ > | Result | > +---------+--+ > +---------+--+ > No rows selected (0.646 seconds) > SELECT > 0: jdbc:hive2://192.168.2.126:10000> select min(c1_int),max(c1_int),sum(c1_int),avg(c1_int) , count(c1_int), variance(c1_int) from Test_Boundary_h1 where rand(c1_int)=0.6201007799387834 or rand(c1_int)=0.45540022789662593 > 0: jdbc:hive2://192.168.2.126:10000> ; > +-------+-------+-------+-------+------+-------+--+ > | _c0 | _c1 | _c2 | _c3 | _c4 | _c5 | > +-------+-------+-------+-------+------+-------+--+ > | NULL | NULL | NULL | NULL | 0 | NULL | > +-------+-------+-------+-------+------+-------+--+ > 1 row selected (1.015 seconds) -- This message was sent by Atlassian JIRA (v6.3.15#6346) |
Free forum by Nabble | Edit this page |