Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 22B52200BB7 for ; Wed, 26 Oct 2016 08:06:00 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 20741160B02; Wed, 26 Oct 2016 06:06:00 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 8D012160AD8 for ; Wed, 26 Oct 2016 08:05:59 +0200 (CEST) Received: (qmail 99935 invoked by uid 500); 26 Oct 2016 06:05:58 -0000 Mailing-List: contact issues-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 issues@hive.apache.org Received: (qmail 99921 invoked by uid 99); 26 Oct 2016 06:05:58 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Oct 2016 06:05:58 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 5803D2C014E for ; Wed, 26 Oct 2016 06:05:58 +0000 (UTC) Date: Wed, 26 Oct 2016 06:05:58 +0000 (UTC) From: "Chao Sun (JIRA)" To: issues@hive.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HIVE-15056) Support index shifting for struct fields MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 26 Oct 2016 06:06:00 -0000 [ https://issues.apache.org/jira/browse/HIVE-15056?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Chao Sun updated HIVE-15056: ---------------------------- Attachment: HIVE-15056.2.patch > Support index shifting for struct fields > ---------------------------------------- > > Key: HIVE-15056 > URL: https://issues.apache.org/jira/browse/HIVE-15056 > Project: Hive > Issue Type: Sub-task > Components: File Formats, Physical Optimizer, Serializers/Deserializers > Reporter: Chao Sun > Assignee: Chao Sun > Attachments: HIVE-15056.1.patch, HIVE-15056.2.patch > > > In HIVE-13873, the following case doesn't work: > {code} > select s.c from tbl > {code} > where {{tbl}} is of schema: > {code} > a int > s struct > {code} > This is because currently we generate a "pruned" schema (in terms of {{GroupType}}) for Parquet reader to scan the data. However, on the Hive side the object inspector still uses the original schema. In particular, in this case for {{s.c}} the data returned by Parquet reader is in index 0, but the object inspector tries to read it in index 1. Therefore, in correct result will be returned. -- This message was sent by Atlassian JIRA (v6.3.4#6332)