You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Aitozi (via GitHub)" <gi...@apache.org> on 2023/04/11 13:52:43 UTC

[GitHub] [flink] Aitozi commented on a diff in pull request #22376: [FLINK-31767][table-planner] Improve the implementation for "analyze table" execution on partitioned table

Aitozi commented on code in PR #22376:
URL: https://github.com/apache/flink/pull/22376#discussion_r1162852786


##########
flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/api/internal/AnalyzeTableUtil.java:
##########
@@ -137,13 +138,46 @@ private static CatalogColumnStatistics mergeColumnStatistics(
         if (!columns.isEmpty()) {
             columnStat = convertToColumnStatistics(row, columns);
         }
-        return new Tuple2<>(tableStat, columnStat);
+        return new StatisticsWrapper(tableStat, columnStat);
+    }
+
+    private static Map<Integer, StatisticsWrapper> executeSqlAndGenerateStatisticsForMultiParts(
+            TableEnvironmentImpl tableEnv,
+            List<Column> columns,
+            String statSql,
+            int partitionCount) {
+        TableResult tableResult = tableEnv.executeSql(statSql);

Review Comment:
   The empty partition will generate an empty sql here fails the test ci



-- 
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-unsubscribe@flink.apache.org

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