From a134752ac4b85f46ec1d16a0ad930c598c845998 Mon Sep 17 00:00:00 2001 From: "David W. Dougherty" Date: Tue, 10 Sep 2024 08:24:45 -0700 Subject: [PATCH] DEV: add TCEs to query > full-text page --- .../search-and-query/query/full-text.md | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/content/develop/interact/search-and-query/query/full-text.md b/content/develop/interact/search-and-query/query/full-text.md index 791ffbcad7..98a2f27e00 100644 --- a/content/develop/interact/search-and-query/query/full-text.md +++ b/content/develop/interact/search-and-query/query/full-text.md @@ -46,9 +46,9 @@ Words that occur very often in natural language, such as `the` or `a` for the En The following example searches for all bicycles that have the word 'kids' in the description: -``` +{{< clients-example query_ft ft1 >}} FT.SEARCH idx:bicycle "@description: kids" -``` +{{< /clients-example >}} ## Phrase @@ -73,9 +73,9 @@ The prefix needs to be at least two characters long. Here is an example that shows you how to search for bicycles with a brand that starts with 'ka': -``` +{{< clients-example query_ft ft2 >}} FT.SEARCH idx:bicycle "@model: ka*" -``` +{{< /clients-example >}} ## Word suffix @@ -93,9 +93,9 @@ FT.SEARCH index "*infix*" Here is an example that finds all brands that end with 'bikes': -``` +{{< clients-example query_ft ft3 >}} FT.SEARCH idx:bicycle "@brand:*bikes" -``` +{{< /clients-example >}} ## Fuzzy search @@ -109,12 +109,12 @@ FT.SEARCH index "%word%" The following example finds all documents that contain a word that has a distance of one to the incorrectly spelled word 'optamized'. You can see that this matches the word 'optimized'. -``` +{{< clients-example query_ft ft4 >}} FT.SEARCH idx:bicycle "%optamized%" -``` +{{< /clients-example >}} If you want to increase the maximum word distance to two, you can use the following query: -``` +{{< clients-example query_ft ft5 >}} FT.SEARCH idx:bicycle "%%optamised%%" -``` \ No newline at end of file +{{< /clients-example >}} \ No newline at end of file