swuferhong commented on code in PR #20664:
URL: https://github.com/apache/flink/pull/20664#discussion_r953582716


##########
flink-connectors/flink-connector-hive/src/test/java/org/apache/flink/connectors/hive/HiveTableSourceStatisticsReportTest.java:
##########
@@ -292,20 +294,41 @@ private static void 
assertHiveTableOrcFormatTableStatsEquals(
         expectedColumnStatsMap.put(
                 "f_string",
                 new 
ColumnStats.Builder().setMax("def").setMin("abcd").setNullCount(0L).build());
-        expectedColumnStatsMap.put(
-                "f_decimal5",
-                new ColumnStats.Builder()
-                        .setMax(new BigDecimal("223.45"))
-                        .setMin(new BigDecimal("123.45"))
-                        .setNullCount(0L)
-                        .build());
-        expectedColumnStatsMap.put(
-                "f_decimal14",
-                new ColumnStats.Builder()
-                        .setMax(new BigDecimal("123333333355.33"))
-                        .setMin(new BigDecimal("123333333333.33"))
-                        .setNullCount(0L)
-                        .build());
+        if (hiveVersion.startsWith("3.")) {
+            // TODO For hive 3.x version, Orc format encounter decimal type 
columns (like decimal(5,
+            // 2), decimal(14, 2)) will write a wrong column stat 'min' in orc 
metadata footer

Review Comment:
   > Actually, I think it may also write a wrong column stat 'max' if the data 
you write is less than 0. Seems we can refine the comment.
   Done!
   



-- 
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: issues-unsubscr...@flink.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to