Return-Path: X-Original-To: apmail-hive-dev-archive@www.apache.org Delivered-To: apmail-hive-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7C00A1089E for ; Fri, 21 Mar 2014 02:16:45 +0000 (UTC) Received: (qmail 58494 invoked by uid 500); 21 Mar 2014 02:16:43 -0000 Delivered-To: apmail-hive-dev-archive@hive.apache.org Received: (qmail 58379 invoked by uid 500); 21 Mar 2014 02:16:43 -0000 Mailing-List: contact dev-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hive.apache.org Delivered-To: mailing list dev@hive.apache.org Received: (qmail 58371 invoked by uid 500); 21 Mar 2014 02:16:43 -0000 Delivered-To: apmail-hadoop-hive-dev@hadoop.apache.org Received: (qmail 58368 invoked by uid 99); 21 Mar 2014 02:16:43 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Mar 2014 02:16:43 +0000 Date: Fri, 21 Mar 2014 02:16:43 +0000 (UTC) From: "Gunther Hagleitner (JIRA)" To: hive-dev@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HIVE-6716) ORC struct throws NPE for tables with inner structs having null values MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/HIVE-6716?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13942678#comment-13942678 ] Gunther Hagleitner commented on HIVE-6716: ------------------------------------------ +1 LGTM, wondering though if it would be easy to write a unit test for it. > ORC struct throws NPE for tables with inner structs having null values > ----------------------------------------------------------------------- > > Key: HIVE-6716 > URL: https://issues.apache.org/jira/browse/HIVE-6716 > Project: Hive > Issue Type: Bug > Affects Versions: 0.13.0, 0.14.0 > Reporter: Prasanth J > Assignee: Prasanth J > Labels: orcfile > Attachments: HIVE-6716.1.patch > > > ORCStruct should return null when object passed to getStructFieldsDataAsList(Object obj) is null. > {code} > public List getStructFieldsDataAsList(Object object) { > OrcStruct struct = (OrcStruct) object; > List result = new ArrayList(struct.fields.length); > {code} > In the above code struct.fields will throw NPE if struct is NULL. -- This message was sent by Atlassian JIRA (v6.2#6252)