cloud-fan commented on code in PR #45537:
URL: https://github.com/apache/spark/pull/45537#discussion_r1593536803


##########
sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/jdbc/JdbcUtils.scala:
##########
@@ -500,7 +501,11 @@ object JdbcUtils extends Logging with SQLConfHelper {
 
     case TimestampType =>
       (rs: ResultSet, row: InternalRow, pos: Int) =>
-        val t = rs.getTimestamp(pos + 1)
+        val t = dialect.getDatabaseCalendar match {
+          case Some(cal) => rs.getTimestamp(pos + 1, cal)

Review Comment:
   shall we always call `get/setTimestamp` with a calendar instance of the 
session local timezone? We can add a config to restore the old behavior, 
instead of adding a new API in Dialect.



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

Reply via email to