Return-Path: X-Original-To: apmail-drill-issues-archive@minotaur.apache.org Delivered-To: apmail-drill-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1F4F81860D for ; Tue, 21 Jul 2015 23:51:05 +0000 (UTC) Received: (qmail 26711 invoked by uid 500); 21 Jul 2015 23:51:05 -0000 Delivered-To: apmail-drill-issues-archive@drill.apache.org Received: (qmail 26682 invoked by uid 500); 21 Jul 2015 23:51:05 -0000 Mailing-List: contact issues-help@drill.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@drill.apache.org Delivered-To: mailing list issues@drill.apache.org Received: (qmail 26672 invoked by uid 99); 21 Jul 2015 23:51:05 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Jul 2015 23:51:05 +0000 Date: Tue, 21 Jul 2015 23:51:04 +0000 (UTC) From: "Jacques Nadeau (JIRA)" To: issues@drill.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (DRILL-3476) Filter on nested element gives wrong results 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/DRILL-3476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jacques Nadeau updated DRILL-3476: ---------------------------------- Fix Version/s: 1.2.0 > Filter on nested element gives wrong results > -------------------------------------------- > > Key: DRILL-3476 > URL: https://issues.apache.org/jira/browse/DRILL-3476 > Project: Apache Drill > Issue Type: Bug > Reporter: Steven Phillips > Assignee: Hanifi Gunes > Priority: Critical > Fix For: 1.2.0 > > > Take this query for example: > {code} > 0: jdbc:drill:drillbit=localhost> select * from t; > +----------------+ > | a | > +----------------+ > | {"b":1,"c":1} | > +----------------+ > {code} > if I instead run: > {code} > 0: jdbc:drill:drillbit=localhost> select a from t where t.a.b = 1; > +----------------+ > | a | > +----------------+ > | {"b":1} | > +----------------+ > {code} > Only a.b was returned, but the select specified a. In this case, it should have returned all of the elements of a, not just the one specified in the filter. > This is because the logic in FieldSelection does not correctly handle the case where a selected column is a child of another selected column. In such a case, the record reader should ignore the child column, and just return the full selected parent column. -- This message was sent by Atlassian JIRA (v6.3.4#6332)