BilboDai created HIVE-23411:
-------------------------------

             Summary: conditional aggregation in Windowing and Analytics 
Functions 
                 Key: HIVE-23411
                 URL: https://issues.apache.org/jira/browse/HIVE-23411
             Project: Hive
          Issue Type: Improvement
            Reporter: BilboDai


{{select }}{{sum(if(datediff(#order_date,order_date) <= 30, price, 0) 
over(partition by city_code order by order_date) as total_price_within_30days}}

sql above is trying to aggregate each city's total order price within 30 days 
according to each city's daily record. is it possible to support that 
conditional aggregation in window function, _#order_date_ means the order date 
of current row which being processed. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to