rubenada commented on code in PR #4181:
URL: https://github.com/apache/calcite/pull/4181#discussion_r1946844297


##########
core/src/main/java/org/apache/calcite/sql2rel/RelDecorrelator.java:
##########
@@ -795,6 +801,146 @@ private static void shiftMapping(Map<Integer, Integer> 
mapping, int startIndex,
     return null;
   }
 
+  private @Nullable Frame decorrelateFetchOneSort(Sort sort, final Frame 
frame) {

Review Comment:
   Maybe I'm a bit too paranoid, but just to be on the safe side, I'd propose 
the new methods (`decorrelateFetchOneSort` and `decorrelateSortAsAggregate`) to 
be `protected` instead of `private`; the reason is that if, for whatever 
reason, a downstream project wants to "switch off" this conversion, they could 
simply extend the RelDecorrletor with their own child class and override these 
methods to simply return `null`, right?



##########
core/src/main/java/org/apache/calcite/sql2rel/RelDecorrelator.java:
##########
@@ -795,6 +801,146 @@ private static void shiftMapping(Map<Integer, Integer> 
mapping, int startIndex,
     return null;
   }
 
+  private @Nullable Frame decorrelateFetchOneSort(Sort sort, final Frame 
frame) {

Review Comment:
   Maybe I'm a bit too paranoid, but just to be on the safe side, I'd propose 
the new methods (`decorrelateFetchOneSort` and `decorrelateSortAsAggregate`) to 
be `protected` instead of `private`; the reason is that if, for whatever 
reason, a downstream project wants to "switch off" this conversion, they could 
simply extend the RelDecorreletor with their own child class and override these 
methods to simply return `null`, right?



-- 
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]

Reply via email to