[ 
https://issues.apache.org/jira/browse/HIVE-14694?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15460601#comment-15460601
 ] 

Hive QA commented on HIVE-14694:
--------------------------------



Here are the results of testing the latest attachment:
https://issues.apache.org/jira/secure/attachment/12826791/HIVE-14694.1.patch

{color:red}ERROR:{color} -1 due to no test(s) being added or modified.

{color:red}ERROR:{color} -1 due to 8 failed/errored test(s), 10441 tests 
executed
*Failed tests:*
{noformat}
TestBeeLineWithArgs - did not produce a TEST-*.xml file
TestHiveCli - did not produce a TEST-*.xml file
org.apache.hadoop.hive.cli.TestCliDriver.org.apache.hadoop.hive.cli.TestCliDriver
org.apache.hadoop.hive.cli.TestCliDriver.testCliDriver[vector_join_part_col_char]
org.apache.hadoop.hive.cli.TestMiniLlapCliDriver.testCliDriver[acid_bucket_pruning]
org.apache.hadoop.hive.cli.TestMiniTezCliDriver.testCliDriver[explainuser_3]
org.apache.hive.hcatalog.hbase.TestPigHBaseStorageHandler.org.apache.hive.hcatalog.hbase.TestPigHBaseStorageHandler
org.apache.hive.jdbc.TestJdbcWithMiniHS2.testAddJarConstructorUnCaching
{noformat}

Test results: 
https://builds.apache.org/job/PreCommit-HIVE-MASTER-Build/1089/testReport
Console output: 
https://builds.apache.org/job/PreCommit-HIVE-MASTER-Build/1089/console
Test logs: 
http://ec2-204-236-174-241.us-west-1.compute.amazonaws.com/logs/PreCommit-HIVE-MASTER-Build-1089/

Messages:
{noformat}
Executing org.apache.hive.ptest.execution.TestCheckPhase
Executing org.apache.hive.ptest.execution.PrepPhase
Executing org.apache.hive.ptest.execution.ExecutionPhase
Executing org.apache.hive.ptest.execution.ReportingPhase
Tests exited with: TestsFailedException: 8 tests failed
{noformat}

This message is automatically generated.

ATTACHMENT ID: 12826791 - PreCommit-HIVE-MASTER-Build

> UDF rand throws NPE when input data is NULL
> -------------------------------------------
>
>                 Key: HIVE-14694
>                 URL: https://issues.apache.org/jira/browse/HIVE-14694
>             Project: Hive
>          Issue Type: Bug
>          Components: UDF
>    Affects Versions: 2.2.0
>            Reporter: Niklaus Xiao
>            Assignee: Niklaus Xiao
>            Priority: Minor
>             Fix For: 2.2.0
>
>         Attachments: HIVE-14694.1.patch
>
>
> When use {{rand}} function with null, HiveServer throws NPE:
> {code}
> 0: jdbc:hive2://10.64.35.144:21066/> desc foo1;
> +-----------+------------+----------+--+
> | col_name  | data_type  | comment  |
> +-----------+------------+----------+--+
> | c1        | bigint     |          |
> +-----------+------------+----------+--+
> 1 row selected (0.075 seconds)
> 0: jdbc:hive2://10.64.35.144:21066/> select * from foo1;
> +----------+--+
> | foo1.c1  |
> +----------+--+
> | NULL     |
> | 1        |
> | 2        |
> +----------+--+
> 3 rows selected (0.124 seconds)
> 0: jdbc:hive2://10.64.35.144:21066/> select rand(c1) from foo1;
> Error: java.io.IOException: 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@37a2b47b of class 
> org.apache.hadoop.hive.ql.udf.UDFRand with arguments {null} of size 1 
> (state=,code=0)
> {code}
> Stack trace:
> {code}
> Caused by: java.lang.reflect.InvocationTargetException
>         at sun.reflect.GeneratedMethodAccessor79.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:1010)
>         ... 36 more
> Caused by: java.lang.NullPointerException
>         at org.apache.hadoop.hive.ql.udf.UDFRand.evaluate(UDFRand.java:57)
>         ... 40 more
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to