Jackie-Jiang commented on a change in pull request #5795:
URL: https://github.com/apache/incubator-pinot/pull/5795#discussion_r465386143



##########
File path: 
pinot-common/src/main/java/org/apache/pinot/common/function/AggregationFunctionType.java
##########
@@ -101,6 +101,13 @@ public static AggregationFunctionType 
getAggregationFunctionType(String function
       try {
         return AggregationFunctionType.valueOf(upperCaseFunctionName);
       } catch (Exception e) {
+        if (upperCaseFunctionName.contains("_")) {
+          try {
+            return 
AggregationFunctionType.valueOf(upperCaseFunctionName.replace("_", ""));

Review comment:
       Check if it contains underscore before the second lookup for performance




----------------------------------------------------------------
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:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to