From 3d46bc0baa68aa594258f2ed5fc60d22a7145f03 Mon Sep 17 00:00:00 2001 From: Erica Sadun Date: Wed, 11 Dec 2024 14:02:33 -0700 Subject: [PATCH] EDU-2441: Updates keyword docs to mention starts_with prefix --- docs/encyclopedia/visibility.mdx | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/docs/encyclopedia/visibility.mdx b/docs/encyclopedia/visibility.mdx index a168f5e070..77d4092b3a 100644 --- a/docs/encyclopedia/visibility.mdx +++ b/docs/encyclopedia/visibility.mdx @@ -144,17 +144,26 @@ Description = 'foo' #### Keyword -For Search Attributes of type `Keyword` like `WorkflowId`, the only kind of partial string matching that works is using BETWEEN for suffixes. +For Search Attributes of type `Keyword` like `WorkflowId`, perform partial string matching using STARTS_WITH for prefixes and BETWEEN for suffixes. -`WorkflowId BETWEEN "order-" AND "order-~"` matches WorkflowIds that have characters after `order-` with ASCII values lower than `~` (126, the highest-value printable character), such as the following: +* `WorkflowId STARTS_WITH "order-"` matches Workflow Ids with the "order-" prefix, regardless of the following text. -``` -order- -order-1234 -order-abracadabra -``` + ``` + order- + order-1234 + order-abracadabra + order-~~~abracadabra + ``` + +* `WorkflowId BETWEEN "order-" AND "order-~"` matches Workflow Ids that have characters after `order-` with ASCII values lower than `~` (126, the highest-value printable character), such as the following: + + ``` + order- + order-1234 + order-abracadabra + ``` -It does not match `order-~~`. + It does not match `order-~~`. :::note Filter Composition Quick Reference