houqp commented on a change in pull request #607:
URL: https://github.com/apache/arrow-datafusion/pull/607#discussion_r657577330



##########
File path: datafusion/src/sql/planner.rs
##########
@@ -2826,6 +2818,16 @@ mod tests {
         quick_test(sql, expected);
     }
 
+    #[test]
+    fn empty_over_dup_with_alias() {
+        let sql = "SELECT order_id oid, MAX(order_id) OVER () max_oid, 
MAX(order_id) OVER () max_oid_dup from orders";
+        let expected = "\
+        Projection: #orders.order_id AS oid, #MAX(orders.order_id) AS max_oid, 
#MAX(orders.order_id) AS max_oid_dup\
+        \n  WindowAggr: windowExpr=[[MAX(#orders.order_id)]]\

Review comment:
       not only the planner, the builder also does this for those who use the 
dataframe apis directly ;)




-- 
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]


Reply via email to