MaxGekk commented on code in PR #56158:
URL: https://github.com/apache/spark/pull/56158#discussion_r3319834173


##########
sql/api/src/main/scala/org/apache/spark/sql/catalyst/encoders/RowEncoder.scala:
##########
@@ -97,6 +99,10 @@ object RowEncoder extends DataTypeErrorsBase {
       case TimestampType if SqlApiConf.get.datetimeJava8ApiEnabled => 
InstantEncoder(lenient)
       case TimestampType => TimestampEncoder(lenient)
       case TimestampNTZType => LocalDateTimeEncoder
+      // Nano timestamp types intentionally do not honor `lenient`: legacy 
`java.sql.Timestamp` /
+      // `java.sql.Date` external types are out of scope for nanosecond 
precision (SPARK-57033).
+      case t: TimestampNTZNanosType => LocalDateTimeNanosEncoder(t.precision)
+      case t: TimestampLTZNanosType => InstantNanosEncoder(t.precision)

Review Comment:
   Let's do that by https://issues.apache.org/jira/browse/SPARK-57101 



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to