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 30BD318859 for ; Fri, 11 Sep 2015 16:25:47 +0000 (UTC) Received: (qmail 9898 invoked by uid 500); 11 Sep 2015 16:25:47 -0000 Delivered-To: apmail-drill-issues-archive@drill.apache.org Received: (qmail 9873 invoked by uid 500); 11 Sep 2015 16:25:47 -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 9780 invoked by uid 99); 11 Sep 2015 16:25:47 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Sep 2015 16:25:46 +0000 Date: Fri, 11 Sep 2015 16:25:46 +0000 (UTC) From: "Sean Hsuan-Yi Chu (JIRA)" To: issues@drill.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (DRILL-3360) Window function defined within another window function 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-3360?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14741078#comment-14741078 ] Sean Hsuan-Yi Chu commented on DRILL-3360: ------------------------------------------ Resolved in commit#: b525692e05c2a562a664093abd46bf68137b4a3b > Window function defined within another window function > ------------------------------------------------------- > > Key: DRILL-3360 > URL: https://issues.apache.org/jira/browse/DRILL-3360 > Project: Apache Drill > Issue Type: Bug > Components: Query Planning & Optimization > Affects Versions: 1.1.0 > Environment: CentOS 4 node cluster > Reporter: Khurram Faraaz > Assignee: Sean Hsuan-Yi Chu > Labels: window_function > Fix For: 1.2.0 > > > Window function defined within another window function, Postgres 9.3 does not support this, Drill supports it and we see results being returned. We should not support this kind of query. > From Postgres 9.3 > {code} > postgres=# select rank() over(order by row_number() over(order by col_int)) from vwOnParq_wCst; > ERROR: window functions are not allowed in window definitions > LINE 1: select rank() over(order by row_number() over(order by col_i... > {code} > From execution on Drill > {code} > 0: jdbc:drill:schema=dfs.tmp> select rank() over(order by row_number() over(order by col_int)) from vwOnParq_wCst; > +---------+ > | EXPR$0 | > +---------+ > | 1 | > | 2 | > | 3 | > | 4 | > | 5 | > | 6 | > | 7 | > | 8 | > | 9 | > | 10 | > | 11 | > | 12 | > | 13 | > | 14 | > | 15 | > | 16 | > | 17 | > | 18 | > | 19 | > | 20 | > | 21 | > | 22 | > | 23 | > | 24 | > | 25 | > | 26 | > | 27 | > | 28 | > | 29 | > | 30 | > +---------+ > 30 rows selected (0.377 seconds) > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)