englefly commented on code in PR #62864:
URL: https://github.com/apache/doris/pull/62864#discussion_r3158009850
##########
fe/fe-core/src/main/java/org/apache/doris/nereids/glue/translator/PhysicalPlanTranslator.java:
##########
@@ -2817,14 +2817,28 @@ public PlanFragment
visitPhysicalLazyMaterialize(PhysicalLazyMaterialize<? exten
return inputPlanFragment;
}
- private boolean shouldUseRowStore(Relation rel) {
+ static boolean canUseRowStoreForLazySlots(List<Slot> lazySlots) {
+ Set<Integer> originalColumnUniqueIds = new HashSet<>();
+ for (Slot lazySlot : lazySlots) {
+ if (!(lazySlot instanceof SlotReference)) {
+ return false;
+ }
+ Optional<Column> originalColumn = ((SlotReference)
lazySlot).getOriginalColumn();
+ if (!originalColumn.isPresent() ||
!originalColumnUniqueIds.add(originalColumn.get().getUniqueId())) {
Review Comment:
add 函数返回true 就表示这个元素已经在集合里了
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]