cloud-fan commented on a change in pull request #25336: [SPARK-28017][SQL] 
Support additional levels of truncations by DATE_TRUNC/TRUNC
URL: https://github.com/apache/spark/pull/25336#discussion_r312006989
 
 

 ##########
 File path: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/datetimeExpressions.scala
 ##########
 @@ -1512,7 +1522,9 @@ case class TruncDate(date: Expression, format: 
Expression)
 @ExpressionDescription(
   usage = """
     _FUNC_(fmt, ts) - Returns timestamp `ts` truncated to the unit specified 
by the format model `fmt`.
-    `fmt` should be one of ["YEAR", "YYYY", "YY", "MON", "MONTH", "MM", "DAY", 
"DD", "HOUR", "MINUTE", "SECOND", "WEEK", "QUARTER"]
+    `fmt` should be one of ["MILLENNIUM", "CENTURY", "DECADE", "YEAR", "YYYY", 
"YY",
+                            "QUARTER", "MON", "MONTH", "MM", "WEEK", "DAY", 
"DD",
+                            "HOUR", "MINUTE", "SECOND", "MICROSECOND", 
"MILLISECOND"]
 
 Review comment:
   nit: `MICROSECOND` is smaller than `MILLISECOND`

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


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to