gortiz commented on code in PR #14690:
URL: https://github.com/apache/pinot/pull/14690#discussion_r1899429931
##########
pinot-common/src/main/java/org/apache/pinot/common/utils/request/RequestUtils.java:
##########
@@ -631,4 +633,32 @@ public static Map<String, String>
getOptionsFromJson(JsonNode request, String op
public static Map<String, String> getOptionsFromString(String optionStr) {
return
Splitter.on(';').omitEmptyStrings().trimResults().withKeyValueSeparator('=').split(optionStr);
}
+
+ public static void applyTimestampIndex(Expression expression, PinotQuery
query) {
+ applyTimestampIndex(expression, query, timeColumnWithGranularity -> true);
+ }
+
+ public static void applyTimestampIndex(
+ Expression expression, PinotQuery query, Predicate<String>
timeColumnWithGranularityPredicate
+ ) {
+ if (!expression.isSetFunctionCall()) {
+ return;
+ }
+ Function function = expression.getFunctionCall();
+ if (!function.getOperator().equalsIgnoreCase("datetrunc")) {
Review Comment:
Done
--
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]