cloud-fan commented on a change in pull request #34984:
URL: https://github.com/apache/spark/pull/34984#discussion_r818432106



##########
File path: 
sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/orc/OrcUtils.scala
##########
@@ -372,12 +385,14 @@ object OrcUtils extends Logging {
       canPruneCols: Boolean,
       dataSchema: StructType,
       resultSchema: StructType,

Review comment:
       I'm thinking about this again. It's a long-standing issue that the 
schema evolution is completely defined by the ORC library, but it's non-trivial 
to fix this and let Spark take control.
   
   So my proposal is: when we generate `resultSchemaString` and set it to the 
ORC reader, we should replace `TimestmapNTZType` with `LongType` in the 
catalyst schema, as we know NTZ is stored as int64 in ORC file.




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