clintropolis commented on code in PR #14463:
URL: https://github.com/apache/druid/pull/14463#discussion_r1239387328


##########
extensions-core/stats/src/main/java/org/apache/druid/query/aggregation/variance/sql/BaseVarianceSqlAggregator.java:
##########


Review Comment:
   I think the approach of #14249 which is adding the `SqlAggFunction` 
equivalent of `OperatorConversions.OperatorBuilder` is probably the better way 
to do this



##########
extensions-core/stats/src/main/java/org/apache/druid/query/aggregation/variance/sql/BaseVarianceSqlAggregator.java:
##########
@@ -137,21 +149,77 @@ public Aggregation toDruidAggregation(
     );
   }
 
+  private static class VarPopSqlAggFunction extends SqlAggFunction
+  {
+    VarPopSqlAggFunction()
+    {
+      super(
+          SqlKind.VAR_POP.name(),
+          null,
+          SqlKind.VAR_POP,
+          ReturnTypes.AVG_AGG_FUNCTION,
+          null,
+          OperandTypes.ANY, // Can be more specific after 
https://github.com/apache/druid/pull/14195 is merged

Review Comment:
   does this mean instead of `OperandTypes.ANY` you would use `OperandTypes.or` 
to check for either numeric or `RowSignatures.complexTypeChecker` with the 
appropriate native complex type? Any reason not to pull that change into this 
PR? it seems generally useful for validating any complex input types



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

Reply via email to