317brian commented on code in PR #17658:
URL: https://github.com/apache/druid/pull/17658#discussion_r1942097377


##########
docs/querying/sql-functions.md:
##########
@@ -1282,22 +1282,68 @@ Returns the following:
 
 ## BLOOM_FILTER
 
-Computes a Bloom filter from values produced by the specified expression.
+Computes a [Bloom filter](../development/extensions-core/bloom-filter.md) from 
values provided in an expression.
 
-* **Syntax**: `BLOOM_FILTER(expr, <NUMERIC>)`
+
+* **Syntax:** `BLOOM_FILTER(expr, numEntries)`  
+  `numEntries` specifies the maximum number of distinct values before the 
false positive rate increases.
 * **Function type:** Aggregation
 
+<details><summary>Example</summary>
+
+The following example returns a Base64-encoded Bloom filter representing the 
set of devices ,`agent_category`, used in Albania:
+
+```sql
+SELECT "country",
+  BLOOM_FILTER(agent_category, 10) as albanian_bloom
+FROM "kttm"
+WHERE "country" = 'Albania'
+GROUP BY "country"
+```
+
+Returns the following:
+
+|`country`| `albanian_bloom`|
+|---| --- | 
+|`Albania`|`BAAAAAgAAACAAEAAAAAAAAAAAEIAAAAAAAAAAAAAAAAAAAAAAAIIAAAAAAAAAAAAAAAAAAIAAAAAAQAAAAAAAAAAAAAA`|
+
+</details>
+
 [Learn more](sql-aggregations.md)
 
 ## BLOOM_FILTER_TEST
 
-Returns true if the expression is contained in a Base64-serialized Bloom 
filter.
+Returns true if an expression is contained in a Base64-encoded [Bloom 
filter](../development/extensions-core/bloom-filter.md) string.
 
-* **Syntax**: `BLOOM_FILTER_TEST(expr, <STRING>)`
+* **Syntax:** `BLOOM_FILTER_TEST(expr, <STRING>)`
 * **Function type:** Scalar, other
 
+<details><summary>Example</summary>
+
+The following example returns `true` when a device type, `agent_category`, 
exists in the Bloom filter representing the set of devices used in Albania:
+
+```sql
+SELECT agent_category,
+BLOOM_FILTER_TEST("agent_category", 
'BAAAAAgAAACAAEAAAAAAAAAAAEIAAAAAAAAAAAAAAAAAAAAAAAIIAAAAAAAAAAAAAAAAAAIAAAAAAQAAAAAAAAAAAAAA')
 AS bloom_test
+FROM "kttm"
+GROUP BY 1```

Review Comment:
   The triple back ticks need to go on the next line. That's what is breaking 
the link checking



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