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/03/26 07:07:03 UTC

[GitHub] [spark] cloud-fan commented on a change in pull request #28024: [SPARK-31254][SQL] Use the current session time zone in `HiveResult.toHiveString`

cloud-fan commented on a change in pull request #28024: [SPARK-31254][SQL] Use the current session time zone in `HiveResult.toHiveString`
URL: https://github.com/apache/spark/pull/28024#discussion_r398354681
 
 

 ##########
 File path: sql/core/src/main/scala/org/apache/spark/sql/execution/HiveResult.scala
 ##########
 @@ -59,9 +59,9 @@ object HiveResult {
         .map(_.mkString("\t"))
   }
 
-  private lazy val zoneId = DateTimeUtils.getZoneId(SQLConf.get.sessionLocalTimeZone)
-  private lazy val dateFormatter = DateFormatter(zoneId)
-  private lazy val timestampFormatter = TimestampFormatter.getFractionFormatter(zoneId)
+  private def zoneId = DateTimeUtils.getZoneId(SQLConf.get.sessionLocalTimeZone)
+  private def dateFormatter = DateFormatter(zoneId)
+  private def timestampFormatter = TimestampFormatter.getFractionFormatter(zoneId)
 
 Review comment:
   It's SQLConf.get.sessionLocalTimeZone

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


With regards,
Apache Git Services

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