jihoonson commented on a change in pull request #8487: Add initial SQL support 
for non-expression sketch postaggs
URL: https://github.com/apache/incubator-druid/pull/8487#discussion_r327921084
 
 

 ##########
 File path: docs/querying/sql.md
 ##########
 @@ -363,6 +366,44 @@ All 'array' references in the multi-value string function 
documentation can refe
 | `MV_TO_STRING(arr,str)` | joins all elements of arr by the delimiter 
specified by str |
 | `STRING_TO_MV(str1,str2)` | splits str1 into an array on the delimiter 
specified by str2 |
 
+### Sketch operators
+
+These functions operate on expressions or columns that return sketch objects.
+
+#### HLL sketch operators
+
+The following functions operate on [DataSketches HLL 
sketches](../development/extensions-core/datasketches-hll.html).
+The [DataSketches 
extension](../development/extensions-core/datasketches-extension.html) must be 
loaded to use the following functions.
+
+|Function|Notes|
+|--------|-----|
+|`HLL_SKETCH_ESTIMATE(expr)`|Returns the distinct count estimate from an HLL 
sketch. `expr` must return an HLL sketch.|
+|`HLL_SKETCH_ESTIMATE_WITH_ERROR_BOUNDS(expr, [numStdDev])`|Returns the 
distinct count estimate and error bounds from an HLL sketch. `expr` must return 
an HLL sketch. An optional `numStdDev` argument can be provided.|
 
 Review comment:
   Hmm, `estimate` sounds unclear what it estimates to me. How about 
`HLL_SKETCH_COUNT_DISTINCT` (or `APPROX_COUNT_DISTINCT_DS_HLL` if it's same)? 
Also, does it make sense to use the same name for this and the above function? 
It sounds like `HLL_SKETCH_ESTIMATE(expr)` should use a default error bound.

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


With regards,
Apache Git Services

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

Reply via email to