hvanhovell commented on code in PR #47464: URL: https://github.com/apache/spark/pull/47464#discussion_r1692311896
########## connect/server/src/main/scala/org/apache/spark/sql/connect/planner/SparkConnectPlanner.scala: ########## @@ -1893,33 +1855,6 @@ class SparkConnectPlanner( val unit = extractString(children(0), "unit") Some(TimestampAdd(unit, children(1), children(2))) - case "window" if Seq(2, 3, 4).contains(fun.getArgumentsCount) => - val children = fun.getArgumentsList.asScala.map(transformExpression) - val timeCol = children.head - val windowDuration = extractString(children(1), "windowDuration") - var slideDuration = windowDuration - if (fun.getArgumentsCount >= 3) { - slideDuration = extractString(children(2), "slideDuration") - } - var startTime = "0 second" - if (fun.getArgumentsCount == 4) { - startTime = extractString(children(3), "startTime") - } - Some( - Alias(TimeWindow(timeCol, windowDuration, slideDuration, startTime), "window")( - nonInheritableMetadataKeys = Seq(Dataset.DATASET_ID_KEY, Dataset.COL_POS_KEY))) - - case "session_window" if fun.getArgumentsCount == 2 => - val children = fun.getArgumentsList.asScala.map(transformExpression) - val timeCol = children.head - val sessionWindow = children.last match { - case Literal(s, StringType) if s != null => SessionWindow(timeCol, s.toString) - case other => SessionWindow(timeCol, other) - } - Some( - Alias(sessionWindow, "session_window")(nonInheritableMetadataKeys = Review Comment: @zhengruifeng Why do you explicitly remove the `Dataset.DATASET_ID_KEY` and `Dataset.COL_POS_KEY`? -- 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-unsubscr...@spark.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org