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 19:59:26 UTC

[jira] [Updated] (DRILL-3647) Handle null as input to window function NTILE

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

Khurram Faraaz updated DRILL-3647:
----------------------------------
    Assignee: Deneche A. Hakim

> Handle null as input to window function NTILE 
> ----------------------------------------------
>
>                 Key: DRILL-3647
>                 URL: https://issues.apache.org/jira/browse/DRILL-3647
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Query Planning & Optimization
>    Affects Versions: 1.2.0
>         Environment: private-branch https://github.com/adeneche/incubator-drill/tree/new-window-funcs
>            Reporter: Khurram Faraaz
>            Assignee: Deneche A. Hakim
>              Labels: window_function
>             Fix For: Future
>
>
> We need to handle null as input to window functions. NTILE function must return null as output when input is null.
> {code}
> 0: jdbc:drill:schema=dfs.tmp> select col7 , col0 , ntile(null) over(partition by col7 order by col0) lead_col0 from FEWRWSPQQ_101;
> Error: PARSE ERROR: From line 1, column 22 to line 1, column 37: Argument to function 'NTILE' must not be NULL
> [Error Id: e5e69582-8502-4a99-8ba1-dffdfb8ac028 on centos-04.qa.lab:31010] (state=,code=0)
> {code}
> {code}
> 0: jdbc:drill:schema=dfs.tmp> select col7 , col0 , lead(null) over(partition by col7 order by col0) lead_col0 from FEWRWSPQQ_101;
> Error: PARSE ERROR: From line 1, column 27 to line 1, column 30: Illegal use of 'NULL'
> [Error Id: 6824ca01-e3f1-4338-b4c8-5535e7a42e13 on centos-04.qa.lab:31010] (state=,code=0)
> {code}



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