morrySnow commented on code in PR #31576: URL: https://github.com/apache/doris/pull/31576#discussion_r1507123605
########## fe/fe-core/src/main/java/org/apache/doris/catalog/OlapTable.java: ########## @@ -501,7 +501,8 @@ public List<Long> getMvColumnIndexIds(String columnName) { for (MaterializedIndexMeta meta : getVisibleIndexIdToMeta().values()) { Column target = meta.getColumnByDefineName(columnName); if (target != null) { - ids.add(meta.getIndexId()); + // Return -1 for base index. This is for compatible with older version of column stats. + ids.add(meta.getIndexId() == baseIndexId ? -1 : meta.getIndexId()); Review Comment: It seems that this interface is specifically designed for statistical information. Please add some comments to clarify its purpose and usage. -- 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: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org