You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Khurram Faraaz (JIRA)" <ji...@apache.org> on 2015/10/08 20:07:26 UTC

[jira] [Updated] (DRILL-3597) Disable RESPECT NULLS, IGNORE NULLS option for LEAD, LAG window functions

     [ https://issues.apache.org/jira/browse/DRILL-3597?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Khurram Faraaz updated DRILL-3597:
----------------------------------
    Fix Version/s:     (was: Future)
                   1.3.0

> Disable RESPECT NULLS, IGNORE NULLS option for LEAD, LAG window functions
> -------------------------------------------------------------------------
>
>                 Key: DRILL-3597
>                 URL: https://issues.apache.org/jira/browse/DRILL-3597
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Execution - Relational Operators
>    Affects Versions: 1.2.0
>            Reporter: Khurram Faraaz
>             Fix For: 1.3.0
>
>
> The SQL standard defines a RESPECT NULLS or IGNORE NULLS option for lead, lag, first_value, and last_value window functions. We need to (disable it) and report a meaningful message to user if either of these two options is used in a query, with any of those functions.
> Currently we throw parse errors when these options are used in query.
> {code}
> 0: jdbc:drill:schema=dfs.tmp> select lead(c1,2) respect nulls over w from union_01 window w as (partition by c3 order by c1);
> Error: PARSE ERROR: Encountered "nulls" at line 1, column 27.
> Was expecting one of:
>     "FROM" ...
>     "," ...
>    
> [Error Id: 73d09692-6374-41a2-bce0-db73d2828f1f on centos-04.qa.lab:31010] (state=,code=0)
> {code}
> {code}
> 0: jdbc:drill:schema=dfs.tmp> select lead(c1,2) ignore nulls over w from union_01 window w as (partition by c3 order by c1);
> Error: PARSE ERROR: Encountered "nulls" at line 1, column 26.
> Was expecting one of:
>     "FROM" ...
>     "," ...
>     
> [Error Id: a7bd21b3-b46c-417d-a9d9-aa6d0378b0fc on centos-04.qa.lab:31010] (state=,code=0)
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)