You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "zml1206 (via GitHub)" <gi...@apache.org> on 2023/09/27 11:29:51 UTC

[GitHub] [spark] zml1206 commented on a diff in pull request #43144: [SPARK-45352][SQL] Remove window partition if partition expressions are foldable

zml1206 commented on code in PR #43144:
URL: https://github.com/apache/spark/pull/43144#discussion_r1338463707


##########
sql/core/src/test/scala/org/apache/spark/sql/DataFrameWindowFramesSuite.scala:
##########
@@ -513,4 +513,14 @@ class DataFrameWindowFramesSuite extends QueryTest with SharedSparkSession {
       df,
       Row(1) :: Row(1) :: Nil)
   }
+
+  test("SPARK-45352: Remove window partition if partition expression are foldable") {
+    val ds = Seq(1, 2, 3).toDF("i")
+    val sortOrder = SortOrder($"i".expr, Ascending)
+    val window1 = new WindowSpec(Seq(), Seq(sortOrder), UnspecifiedFrame)
+    val window2 = new WindowSpec(Seq(lit(1).expr), Seq(sortOrder), UnspecifiedFrame)

Review Comment:
   @beliefer Thanks, updated all.



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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org