abhishekagarwal87 commented on a change in pull request #10350:
URL: https://github.com/apache/druid/pull/10350#discussion_r486249916
##########
File path: docs/querying/sql.md
##########
@@ -561,6 +561,8 @@ The [DataSketches
extension](../development/extensions-core/datasketches-extensi
|`COALESCE(value1, value2, ...)`|Returns the first value that is neither NULL
nor empty string.|
|`NVL(expr,expr-for-null)`|Returns 'expr-for-null' if 'expr' is null (or empty
string for string type).|
|`BLOOM_FILTER_TEST(<expr>, <serialized-filter>)`|Returns true if the value is
contained in a Base64-serialized bloom filter. See the [Bloom filter
extension](../development/extensions-core/bloom-filter.html) documentation for
additional details.|
+|`CONTAINS_STR(<expr>, str)`|Returns true if the `str` is a substring of
`expr`.|
+|`ICONTAINS_STR(<expr>, str)`|Returns true if the `str` is a substring of
`expr`. The match is case-insensitive.|
Review comment:
- mysql and postgres - They have substring functions that return the
starting index of a search string. I did not find any function similar to
`contains`. Oracle has a similar function which is called `instr`
- Snowflake has a `contains` function similar to ours though there is no
case insensitive flavor.
- Presto does not seem to have a `contains` method but does have the
methods to find the starting index of another string.
- BigQuery has `REGEXP_CONTAINS` which takes a regular expression as an
input.
`CONTAINS` would have been an ideal choice for the name but alas, that
conflicts with the existing calcite operator. I can certainly rename them to
`CONTAINS_STRING`
----------------------------------------------------------------
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]