cdmikechen commented on code in PR #8955:
URL: https://github.com/apache/hudi/pull/8955#discussion_r1229552284


##########
hudi-hadoop-mr/src/main/java/org/apache/hudi/hadoop/HoodieColumnProjectionUtils.java:
##########
@@ -112,22 +120,53 @@ public static List<Pair<String,String>> 
getIOColumnNameAndTypes(Configuration co
   /**
    * If schema contains timestamp columns, this method is used for 
compatibility when there is no timestamp fields.
    *
-   * <p>We expect 3 cases to use parquet-avro reader {@link 
org.apache.hudi.hadoop.avro.HoodieAvroParquetReader} to read timestamp column:
+   * <p>We expect 2 cases to use parquet-avro reader {@link 
org.apache.hudi.hadoop.avro.HoodieAvroParquetReader} to read timestamp column:
    *
    * <ol>
    *   <li>Read columns contain timestamp type;</li>
    *   <li>Empty original columns;</li>
-   *   <li>Empty read columns but existing original columns contain timestamp 
type.</li>
    * </ol>
    */
   public static boolean supportTimestamp(Configuration conf) {
     List<String> readCols = Arrays.asList(getReadColumnNames(conf));
     if (readCols.isEmpty()) {
-      return getIOColumnTypes(conf).contains("timestamp");
+      return false;
+    }
+
+    String colTypes = conf.get(IOConstants.COLUMNS_TYPES, "");
+    if (colTypes == null || colTypes.isEmpty()) {
+      return true;

Review Comment:
   It seems inside my memory that some of the Hive test cases at that time were 
not configured rightly for test initialization. To be compatible with some 
errors, so I didn't do the return directly. 
   If there's no problem with CI now, I think it should be OK.



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

Reply via email to