huangmengbin commented on a change in pull request #5991: URL: https://github.com/apache/incubator-doris/pull/5991#discussion_r656204388
########## File path: fe/fe-core/src/main/java/org/apache/doris/planner/RangePartitionPruner.java ########## @@ -75,19 +75,21 @@ public RangePartitionPruner(Map<Long, PartitionItem> rangeMap, Column keyColumn = partitionColumns.get(columnIdx); PartitionColumnFilter filter = partitionColumnFilters.get(keyColumn.getName()); if (null == filter) { - minKey.pushColumn(LiteralExpr.createInfinity(Type.fromPrimitiveType(keyColumn.getDataType()), false), - keyColumn.getDataType()); - maxKey.pushColumn(LiteralExpr.createInfinity(Type.fromPrimitiveType(keyColumn.getDataType()), true), - keyColumn.getDataType()); + int pushMinCount = minKey.fillWithInfinity(partitionColumns, false); Review comment: > If there is no condition in the first column, should we directly add the infinity range of the first column, right? Yes, it might be true. If the columnIdx is 0, we only need to add an infinity range of the first column. there is no need to add the infinity range for all columns. Thanks for your review ! -- 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 --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org