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 D909C188D8 for ; Thu, 17 Mar 2016 15:56:33 +0000 (UTC) Received: (qmail 23481 invoked by uid 500); 17 Mar 2016 15:56:33 -0000 Delivered-To: apmail-drill-issues-archive@drill.apache.org Received: (qmail 23412 invoked by uid 500); 17 Mar 2016 15:56:33 -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 23384 invoked by uid 99); 17 Mar 2016 15:56:33 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 17 Mar 2016 15:56:33 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 8301F2C14F8 for ; Thu, 17 Mar 2016 15:56:33 +0000 (UTC) Date: Thu, 17 Mar 2016 15:56:33 +0000 (UTC) From: "Serge Harnyk (JIRA)" To: issues@drill.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (DRILL-4436) Result data gets mixed up when various tables have a column "label" 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-4436?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15199767#comment-15199767 ] Serge Harnyk commented on DRILL-4436: ------------------------------------- I think the problem is more serious. I created two same tables Gender2 and Civility2 with columns "label2" in BOTH tables. select gender2.label2 as label2 from postgres.public.gender2 join postgres.public.civility2 on genderId = civilityId returns: civilityLabel select civility2.label2 as label2 from postgres.public.gender2 join postgres.public.civility2 on genderId = civilityId returns: null select gender2.label2, civility2.label2 from postgres.public.gender2 join postgres.public.civility2 on genderId = civilityId returns: civilityLabel null Project step works wrong when we select column with same name that in second table. Regardless its name. > Result data gets mixed up when various tables have a column "label" > ------------------------------------------------------------------- > > Key: DRILL-4436 > URL: https://issues.apache.org/jira/browse/DRILL-4436 > Project: Apache Drill > Issue Type: Bug > Components: Storage - JDBC > Affects Versions: 1.5.0 > Environment: Drill 1.5.0 with Zookeeper on CentOS 7.0 > Reporter: Vincent Uribe > Assignee: Serge Harnyk > > We have two tables in a MySQL database: > CREATE TABLE `Gender` ( > `genderId` bigint(20) NOT NULL AUTO_INCREMENT, > `label` varchar(15) NOT NULL, > PRIMARY KEY (`genderId`) > ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1; > CREATE TABLE `Civility` ( > `civilityId` bigint(20) NOT NULL AUTO_INCREMENT, > `abbreviation` varchar(15) NOT NULL, > `label` varchar(60) DEFAULT NULL > PRIMARY KEY (`civilityId`) > ) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=latin1; > With a query on these two tables with Gender.label as 'gender' and Civility.label as 'civility', we obtain, depending of the query : > * gender in civility > * civility in the gender > * NULL in the other column (gender or civility) > if we drop the table Gender and recreate it with like this: > CREATE TABLE `Gender` ( > `genderId` bigint(20) NOT NULL AUTO_INCREMENT, > `label2` varchar(15) NOT NULL, > PRIMARY KEY (`genderId`)select * from Gender > ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1; > Everything is fine. > I guess something is wrong with the metadata... -- This message was sent by Atlassian JIRA (v6.3.4#6332)