You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2020/06/01 12:59:56 UTC

[GitHub] [spark] yaooqinn commented on a change in pull request #28692: [SPARK-31879][SQL] Using GB as default Locale for datetime formatters

yaooqinn commented on a change in pull request #28692:
URL: https://github.com/apache/spark/pull/28692#discussion_r433218901



##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/util/DateFormatter.scala
##########
@@ -117,7 +117,16 @@ class LegacySimpleDateFormatter(pattern: String, locale: Locale) extends LegacyD
 object DateFormatter {
   import LegacyDateFormats._
 
-  val defaultLocale: Locale = Locale.US
+  /**
+   * This is change from Locale.US to GB, because:
+   * The first day-of-week varies by culture.
+   * For example, the US uses Sunday, while the United Kingdom and the ISO-8601 standard use Monday.

Review comment:
       It seems that we don't need care about the other differences, e.g. currency symbol
   FYI,
   http://www.localeplanet.com/java/en-GB/index.html and http://www.localeplanet.com/java/en-US/index.html
   
   the timeZone is not the same, but it's a separate field we don't get it from Locale right?




----------------------------------------------------------------
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:
users@infra.apache.org



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