[ 
https://issues.apache.org/jira/browse/HIVE-23665?focusedWorklogId=451666&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-451666
 ]

ASF GitHub Bot logged work on HIVE-23665:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 26/Jun/20 17:42
            Start Date: 26/Jun/20 17:42
    Worklog Time Spent: 10m 
      Work Description: jcamachor commented on a change in pull request #1177:
URL: https://github.com/apache/hive/pull/1177#discussion_r446323133



##########
File path: ql/src/java/org/apache/hadoop/hive/ql/parse/PTFTranslator.java
##########
@@ -142,6 +143,19 @@ public PTFDesc translate(WindowingSpec wdwSpec, 
SemanticAnalyzer semAly, HiveCon
       UnparseTranslator unparseT)
       throws SemanticException {
     init(semAly, hCfg, inputRR, unparseT);
+    for (int i = 0; i < wdwSpec.getWindowExpressions().size(); ++i) {

Review comment:
       Should we do this rewriting via Calcite rule instead of adding this 
custom logic over here?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 451666)
    Time Spent: 40m  (was: 0.5h)

> Rewrite last_value to first_value to enable streaming results
> -------------------------------------------------------------
>
>                 Key: HIVE-23665
>                 URL: https://issues.apache.org/jira/browse/HIVE-23665
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Ramesh Kumar Thangarajan
>            Assignee: Ramesh Kumar Thangarajan
>            Priority: Major
>              Labels: pull-request-available
>         Attachments: HIVE-23665.1.patch, HIVE-23665.2.patch, 
> HIVE-23665.3.patch
>
>          Time Spent: 40m
>  Remaining Estimate: 0h
>
> Rewrite last_value to first_value to enable streaming results
> last_value cannot be streamed because the intermediate results need to be 
> buffered to determine the window result till we get the last row in the 
> window. But if we can rewrite to first_value we can stream the results, 
> although the order of results will not be guaranteed (also not important)



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

Reply via email to