MaxGekk commented on a change in pull request #31148:
URL: https://github.com/apache/spark/pull/31148#discussion_r555658375
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/jdbc/JdbcDialects.scala
##########
@@ -175,7 +176,9 @@ abstract class JdbcDialect extends Serializable with
Logging{
def compileValue(value: Any): Any = value match {
case stringValue: String => s"'${escapeSql(stringValue)}'"
case timestampValue: Timestamp => "'" + timestampValue + "'"
+ case timestampValue: Instant => "'" + timestampValue + "'"
Review comment:
I would guess that the default `Instant` formatting by `toString()`
might be not accepted by dbms. Could you take a look at
`FractionTimestampFormatter`:
https://github.com/apache/spark/blob/3a299aa6480ac22501512cd0310d31a441d7dfdc/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/util/TimestampFormatter.scala#L121
----------------------------------------------------------------
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]