dongjoon-hyun commented on a change in pull request #24018: [SPARK-23749][SQL] 
Replace built-in Hive API (isSub/toKryo) and remove OrcProto.Type usage
URL: https://github.com/apache/spark/pull/24018#discussion_r365607937
 
 

 ##########
 File path: 
sql/hive/src/main/java/org/apache/hadoop/hive/ql/io/orc/SparkOrcNewRecordReader.java
 ##########
 @@ -42,8 +41,11 @@
 
   public SparkOrcNewRecordReader(Reader file, Configuration conf,
       long offset, long length) throws IOException {
-    List<OrcProto.Type> types = file.getTypes();
-    numColumns = (types.size() == 0) ? 0 : types.get(0).getSubtypesCount();
+    if (file.getTypes().isEmpty()) {
 
 Review comment:
   Why do you ask here? `file.getTypes()` seems to be used before this PR.
   Did you see the removed line 45?

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to