robreeves commented on code in PR #50269: URL: https://github.com/apache/spark/pull/50269#discussion_r2001809416
########## sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/datetimeExpressions.scala: ########## @@ -2556,6 +2556,91 @@ case class MakeDate( copy(year = newFirst, month = newSecond, day = newThird) } +// scalastyle:off line.size.limit +@ExpressionDescription( + usage = "_FUNC_(hour, minute, second) - Create time from hour, minute and second fields. If the configuration `spark.sql.ansi.enabled` is false, the function returns NULL on invalid inputs. Otherwise, it will throw an error instead.", Review Comment: I updated this, but needed to create a new error code `DATETIME_FIELD_OUT_OF_BOUNDS_ANSI_ONLY` since the existing one suggests disabling ansi behavior. I decided to create the new code to minimize changes and the change in a public facing error code could be considered a breaking changed. Absent those concerns I would have liked to make the new error code `DATETIME_FIELD_OUT_OF_BOUNDS` and rename the existing one to `DATETIME_FIELD_OUT_OF_BOUNDS_ANSI_OPTIONAL`. -- 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