Return-Path: X-Original-To: apmail-phoenix-dev-archive@minotaur.apache.org Delivered-To: apmail-phoenix-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 08F6717A0E for ; Wed, 1 Apr 2015 07:29:18 +0000 (UTC) Received: (qmail 54192 invoked by uid 500); 1 Apr 2015 07:29:17 -0000 Delivered-To: apmail-phoenix-dev-archive@phoenix.apache.org Received: (qmail 54136 invoked by uid 500); 1 Apr 2015 07:29:17 -0000 Mailing-List: contact dev-help@phoenix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@phoenix.apache.org Delivered-To: mailing list dev@phoenix.apache.org Received: (qmail 54125 invoked by uid 99); 1 Apr 2015 07:29:17 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Apr 2015 07:29:17 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO mail.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with SMTP; Wed, 01 Apr 2015 07:28:56 +0000 Received: (qmail 52044 invoked by uid 99); 1 Apr 2015 07:28:53 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Apr 2015 07:28:53 +0000 Date: Wed, 1 Apr 2015 07:28:53 +0000 (UTC) From: "Alicia Ying Shu (JIRA)" To: dev@phoenix.incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Comment Edited] (PHOENIX-1580) Support UNION ALL MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/PHOENIX-1580?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14390020#comment-14390020 ] Alicia Ying Shu edited comment on PHOENIX-1580 at 4/1/15 7:28 AM: ------------------------------------------------------------------ [~jamestaylor] [~maryannxue] The temp schema is to work around Aggregate projection to replace rowProjector. OrderBy expression is normally column name, it should be the same no matter in the server or in the client. The temp schema is already built with the projection names (column names) as specified in the SQL. All UnionAllIT tests passed with Plan compiled Order By and Limit. Wrapping another Select over current Union All selects we need to specify a table. A dummy table or Null table did not work since parser needs a real table to resolve column information etc. I have to say if we have taken my very early approach of passing down rowProjector, we can simplify the approach quite bit. Given that column names are used to construct the temp schema, no need to wrap another select over. was (Author: aliciashu): [~jamestaylor] [~maryannxue] The temp schema is to work around Aggregate projection to replace rowProjector. OrderBy expression is normally column name, it should be the same no matter in the server or in the client. It applies to alias as well. The temp schema is already built with the projection names (column names) as specified in the SQL. I did not see an issue here. All UnionAllIT tests passed with Plan compiled Order By and Limit. Wrapping another Select over current Union All selects we need to specify a table. A dummy table or Null table did not work since parser needs a real table to resolve column information etc. I have to say if we have taken my very early approach of passing down rowProjector, we can simplify the approach quite bit. Given that column names are used to construct the temp schema, no need to wrap another select over. > Support UNION ALL > ----------------- > > Key: PHOENIX-1580 > URL: https://issues.apache.org/jira/browse/PHOENIX-1580 > Project: Phoenix > Issue Type: Bug > Reporter: Alicia Ying Shu > Assignee: Alicia Ying Shu > Attachments: PHOENIX-1580-grammar.patch, Phoenix-1580-v1.patch, phoenix-1580-v1-wipe.patch, phoenix-1580.patch, unionall-wipe.patch > > > Select * from T1 > UNION ALL > Select * from T2 -- This message was sent by Atlassian JIRA (v6.3.4#6332)