[ 
https://issues.apache.org/jira/browse/CALCITE-883?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16804743#comment-16804743
 ] 

Chunwei Lei edited comment on CALCITE-883 at 3/29/19 9:34 AM:
--------------------------------------------------------------

[~julianhyde], I agree with the idea of [~zhztheplayer] after lots of 
discussion. So I updated the 
[PR#1108|https://github.com/apache/calcite/pull/1108] which reduces many 
changes in the AST layer.

As far as I looked into SQL standard, only four window functions including 
LEAD, LAG, FIRST_VALUE, LAST_VALUE allow null treatment. But in my humble 
opinion, I prefer to keep the broader changes for future expansion since those 
using Calcite can choose to provide this "syntax sugar" for aggregate functions.


was (Author: chunwei lei):
[~julianhyde], I agree with the idea of [~zhztheplayer] after lots of 
discussion. So I updated the [PR 
#1108|[https://github.com/apache/calcite/pull/1108]] which reduces many changes 
in the AST layer.

As far as I looked into SQL standard, only four window functions including 
LEAD, LAG, FIRST_VALUE, LAST_VALUE allow null treatment. But in my humble 
opinion, I prefer to keep the broader changes for future expansion since those 
using Calcite can choose to provide this "syntax sugar" for aggregate functions.

> Support RESPECT NULLS, IGNORE NULLS option for LEAD, LAG, FIRST_VALUE, 
> LAST_VALUE window functions
> --------------------------------------------------------------------------------------------------
>
>                 Key: CALCITE-883
>                 URL: https://issues.apache.org/jira/browse/CALCITE-883
>             Project: Calcite
>          Issue Type: Bug
>          Components: core
>            Reporter: Sean Hsuan-Yi Chu
>            Assignee: Chunwei Lei
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 1h 20m
>  Remaining Estimate: 0h
>
> This issue was brought up in Drill community: 
> (https://issues.apache.org/jira/browse/DRILL-3597)
> For convenience, I copied and pasted the reporter Khurram Faraaz's 
> description here:
> "The SQL standard defines a RESPECT NULLS or IGNORE NULLS option for lead, 
> lag, first_value, and last_value window functions."
> In Calcite, we should have been able to recognized this option.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to