viirya commented on code in PR #56842:
URL: https://github.com/apache/spark/pull/56842#discussion_r3487463894
##########
sql/core/src/test/scala/org/apache/spark/sql/execution/columnar/InMemoryColumnarQuerySuite.scala:
##########
@@ -222,6 +222,36 @@ class InMemoryColumnarQuerySuite extends
SharedSparkSession with AdaptiveSparkPl
}
}
+ test("cache nanosecond-precision timestamp types") {
+ withSQLConf(SQLConf.TIMESTAMP_NANOS_TYPES_ENABLED.key -> "true") {
+ Seq("TIMESTAMP_NTZ(9)", "TIMESTAMP_LTZ(9)").foreach { typeName =>
+ Seq("false", "true").foreach { vectorized =>
+ withSQLConf(SQLConf.CACHE_VECTORIZED_READER_ENABLED.key ->
vectorized) {
Review Comment:
You're right, thanks. Nanosecond timestamps are non-primitive for the
default cache, and `DefaultCachedBatchSerializer.supportsColumnarOutput`
returns `true` only for the primitive types, so they always read back through
the row path -- the `CACHE_VECTORIZED_READER_ENABLED=true` case exercised the
same path as `false`. I've dropped the loop and test the single (row) path,
with a comment noting why (same as `CalendarInterval`/`Variant`/`Decimal`).
--
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]