HyukjinKwon commented on a change in pull request #29886:
URL: https://github.com/apache/spark/pull/29886#discussion_r495697154
##########
File path:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/windowExpressions.scala
##########
@@ -669,7 +669,9 @@ case class NthValue(input: Expression, offsetExpr:
Expression, ignoreNulls: Bool
override lazy val evaluateExpression: AttributeReference = result
- override def toString: String = s"$prettyName($input, $offset)${if
(ignoreNulls) " ignore nulls"}"
+ override def prettyName: String = "nth_value"
+ override def sql: String =
+ s"$prettyName(${input.sql}, $offset)${if (ignoreNulls) " ignore nulls"}"
Review comment:
```suggestion
s"$prettyName(${input.sql}, ${offsetExpr.sql})" + (if (ignoreNulls) "
ignore nulls" else "")
```
----------------------------------------------------------------
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]