diff --git a/content/develop/interact/search-and-query/advanced-concepts/aggregation-syntax.md b/content/develop/interact/search-and-query/advanced-concepts/aggregation-syntax.md new file mode 100644 index 0000000000..2a6131a38e --- /dev/null +++ b/content/develop/interact/search-and-query/advanced-concepts/aggregation-syntax.md @@ -0,0 +1,193 @@ +--- +categories: +- docs +- develop +- stack +- oss +- rs +- rc +- oss +- kubernetes +- clients +description: Order of operations for the FT.AGGREGATE command +linkTitle: Aggregation syntax +title: FT.AGGREGATE order of operations +weight: 2 +--- + +## Overview + +[`FT.AGGREGATE`]({{< relref "/commands/ft.aggregate" >}}) is a powerful Redis Query Engine (RQE) command for performing advanced data aggregation, filtering, sorting, and transformations on indexed hash or JSON documents. This reference page provides a structured breakdown of syntax, ordering rules, and best practices. + +The [main aggregations page]({{< relref "/develop/interact/search-and-query/advanced-concepts/aggregations" >}}) has a simple diagram showing how `FT.AGGREGATE` pipelines are constructed, but it doesn't tell the whole story. For example, you can create more complex aggregation pipelines by applying multiple `REDUCE` functions under a single `GROUPBY` clause, or you can chain groupings and mix in additional mapping steps: + +`GROUPBY` ... `REDUCE` ... `APPLY` ... `GROUPBY` ... `REDUCE` + +{{< note >}} +The examples on this page are based on a hypothetical "products" data set, which you can [download here](./data/products.txt). +{{< /note >}} + +## Syntax and expression ordering + +The `FT.AGGREGATE` command processes multiple expressions in a pipeline. Below is the recommended order: + +1. `index` – the name of your index, which must be the first argument. +1. `query` – your query, which must be the second argument. +1. `FILTER` – filters raw documents before transformations or aggregation. +1. `LOAD` – loads additional document attributes. +1. `APPLY` – applies transformations on fields. +1. `GROUPBY` – groups results by specific fields. +1. `REDUCE` – performs aggregations. For example, `SUM`, `COUNT`, and `AVG`. +1. `SORTBY` – orders the results based on specified fields. +1. `LIMIT` – restricts the number of results returned. +1. `DIALECT 2` - provides for more comprehensive syntax, for example using parameters in `FILTER` expressions. + +Other keywords will be discussed toward the end of this page. + +## When to use `@` + +You must add `@` at the start of a field name in the following circumstances: + +- When referencing fields loaded from documents. In the following example, `price` is a document field and must be prefixed with `@`. + +```sh +FT.AGGREGATE products "*" + LOAD 1 @price + APPLY "@price * 1.1" AS adjusted_price + SORTBY 2 @adjusted_price DESC + LIMIT 0 10 +``` + +- When referencing fields inside a `FILTER` clause that were loaded from documents. + +```sh +FT.AGGREGATE products "*" + LOAD 1 @rating + FILTER "@rating >= 4.5" + LIMIT 0 10 +``` + +- When referencing fields inside `GROUPBY` or `REDUCE` clauses. + +```sh +FT.AGGREGATE products "*" + GROUPBY 1 @category + REDUCE SUM 1 @price AS total_price + LIMIT 0 10 +``` + +- When referencing fields created by `REDUCE` in an `APPLY` or `FILTER` clauses. + +```sh +FT.AGGREGATE products "*" + GROUPBY 1 @category + REDUCE SUM 1 @price AS total_price + APPLY "@total_price * 1.2" AS boosted_price + FILTER "@total_price > 1000" + LIMIT 0 10 +``` + +- When referencing fields created by `APPLY` in another `APPLY` or `FILTER` clause. + +```sh +FT.AGGREGATE products "*" + LOAD 2 @price @discount + APPLY "@price - @discount" AS net_price + APPLY "@net_price * 1.1" AS marked_up + FILTER "@net_price > 200" + LIMIT 0 10 +``` + +- When referencing fields created by `APPLY` in a `SORTBY` clause. + +```sh +FT.AGGREGATE products "*" + LOAD 2 @price @discount + APPLY "@price - @discount" AS net_price + SORTBY 2 @net_price DESC + LIMIT 0 10 +``` + +## GROUPBY with multiple REDUCE operations + +`GROUPBY` can be followed by multiple `REDUCE` operations for different aggregations. + +```sh +FT.AGGREGATE products "*" + GROUPBY 1 @category + REDUCE COUNT 0 AS product_count + REDUCE SUM 1 @price AS total_price + REDUCE AVG 1 @rating AS avg_rating + SORTBY 2 @total_price DESC + LIMIT 0 10 +``` + +## Multiple APPLY operations followed by GROUPBY and REDUCE + +You can use `APPLY` in various ways before and after `GROUPBY` and `REDUCE`. + +```sh +FT.AGGREGATE products "*" + LOAD 3 @price @discount @quantity + APPLY "@price - @discount" AS final_price + APPLY "@final_price * @quantity" AS total_revenue + GROUPBY 1 @category + REDUCE SUM 1 @total_revenue AS total_category_revenue + SORTBY 2 @total_category_revenue DESC + LIMIT 0 10 +``` + +## FILTER and PARAMS + +Use `FILTER` to remove unwanted records, and `PARAMS` to pass values to parameterized queries. + +```sh +FT.AGGREGATE products "*" + LOAD 3 @price @rating @quantity + FILTER "@price >= 500" + FILTER "@rating >= 4.0" + APPLY "@price * @quantity" AS total_value + SORTBY 2 @total_value DESC + LIMIT 0 10 + DIALECT 2 +``` + +## Placement of FILTER before and after GROUPBY/APPLY + +- **Before GROUPBY:** Removes records before aggregation. +- **After GROUPBY:** Filters based on aggregated results. +- **Before APPLY:** Ensures calculations are applied only to certain records. +- **After APPLY:** Filters computed values. + +## LOAD after GROUPBY/REDUCE + +This is not allowed and you'll get a syntax error. + +## Placement rules for specific parameters + +| Parameter | Placement | +|----- |----- | +| `TIMEOUT` | Can be placed anywhere. | +| `LIMIT` | Must be at the end, before `DIALECT`. | +| `WITHCURSOR` | Must be at the end, before `DIALECT`. | +| `SCORER` | Can be placed anywhere. | +| `ADDSCORES` | Must be before sorting. | +| `DIALECT` | Must be at the end. | + +## LIMIT and WITHCURSOR used together + +While you wouldn't ordinarily use `LIMIT` and `WITHCURSOR` together in the same query, you can use them advantageously if doing so fits your workflow. +`LIMIT` returns immediate results, while `WITHCURSOR` retrieves results incrementally using the [cursor API]({{< relref "/develop/interact/search-and-query/advanced-concepts/aggregations/#cursor-api" >}}). + +```sh +FT.AGGREGATE products "*" + GROUPBY 1 @category + REDUCE COUNT 0 AS product_count + LIMIT 0 100 + WITHCURSOR COUNT 3 +``` + +See the following resources for more information: + +- [`FT.AGGREGATE` command page](https://redis.io/docs/latest/commands/ft.aggregate/) +- [RQE source code](https://github.com/RediSearch/RediSearch/tree/master/src/aggregate) diff --git a/content/develop/interact/search-and-query/advanced-concepts/autocomplete.md b/content/develop/interact/search-and-query/advanced-concepts/autocomplete.md index f57f057b71..7aafed1491 100644 --- a/content/develop/interact/search-and-query/advanced-concepts/autocomplete.md +++ b/content/develop/interact/search-and-query/advanced-concepts/autocomplete.md @@ -12,7 +12,7 @@ categories: description: Learn how to use the autocomplete feature of Redis for efficient prefix-based suggestion retrieval. linkTitle: Autocomplete title: Autocomplete with Redis -weight: 1 +weight: 2 --- ## Overview diff --git a/content/develop/interact/search-and-query/advanced-concepts/data/products.txt b/content/develop/interact/search-and-query/advanced-concepts/data/products.txt new file mode 100644 index 0000000000..a1607f45e9 --- /dev/null +++ b/content/develop/interact/search-and-query/advanced-concepts/data/products.txt @@ -0,0 +1,201 @@ +FT.CREATE products ON HASH PREFIX 1 "product:" SCHEMA name TEXT price NUMERIC quantity NUMERIC category TAG discount NUMERIC rating NUMERIC +HSET product:1 name "Product-1" price "28.25" quantity "2" category "Apparel" discount "1.5" rating "3.3" +HSET product:2 name "Product-2" price "31.5" quantity "3" category "Groceries" discount "3.0" rating "3.6" +HSET product:3 name "Product-3" price "34.75" quantity "4" category "Books" discount "4.5" rating "3.9" +HSET product:4 name "Product-4" price "38.0" quantity "5" category "Groceries" discount "6.0" rating "4.2" +HSET product:5 name "Product-5" price "41.25" quantity "6" category "Home" discount "7.5" rating "4.5" +HSET product:6 name "Product-6" price "44.5" quantity "7" category "Home" discount "9.0" rating "4.8" +HSET product:7 name "Product-7" price "47.75" quantity "8" category "Books" discount "10.5" rating "3.0" +HSET product:8 name "Product-8" price "51.0" quantity "9" category "Apparel" discount "12.0" rating "3.3" +HSET product:9 name "Product-9" price "54.25" quantity "10" category "Electronics" discount "13.5" rating "3.6" +HSET product:10 name "Product-10" price "57.5" quantity "1" category "Groceries" discount "15.0" rating "3.9" +HSET product:11 name "Product-11" price "60.75" quantity "2" category "Toys" discount "16.5" rating "4.2" +HSET product:12 name "Product-12" price "64.0" quantity "3" category "Books" discount "18.0" rating "4.5" +HSET product:13 name "Product-13" price "67.25" quantity "4" category "Apparel" discount "19.5" rating "4.8" +HSET product:14 name "Product-14" price "70.5" quantity "5" category "Home" discount "21.0" rating "3.0" +HSET product:15 name "Product-15" price "73.75" quantity "6" category "Electronics" discount "22.5" rating "3.3" +HSET product:16 name "Product-16" price "77.0" quantity "7" category "Home" discount "24.0" rating "3.6" +HSET product:17 name "Product-17" price "80.25" quantity "8" category "Apparel" discount "25.5" rating "3.9" +HSET product:18 name "Product-18" price "83.5" quantity "9" category "Books" discount "27.0" rating "4.2" +HSET product:19 name "Product-19" price "86.75" quantity "10" category "Books" discount "28.5" rating "4.5" +HSET product:20 name "Product-20" price "90.0" quantity "1" category "Home" discount "0.0" rating "4.8" +HSET product:21 name "Product-21" price "93.25" quantity "2" category "Books" discount "1.5" rating "3.0" +HSET product:22 name "Product-22" price "96.5" quantity "3" category "Toys" discount "3.0" rating "3.3" +HSET product:23 name "Product-23" price "99.75" quantity "4" category "Toys" discount "4.5" rating "3.6" +HSET product:24 name "Product-24" price "103.0" quantity "5" category "Electronics" discount "6.0" rating "3.9" +HSET product:25 name "Product-25" price "106.25" quantity "6" category "Electronics" discount "7.5" rating "4.2" +HSET product:26 name "Product-26" price "109.5" quantity "7" category "Home" discount "9.0" rating "4.5" +HSET product:27 name "Product-27" price "112.75" quantity "8" category "Home" discount "10.5" rating "4.8" +HSET product:28 name "Product-28" price "116.0" quantity "9" category "Home" discount "12.0" rating "3.0" +HSET product:29 name "Product-29" price "119.25" quantity "10" category "Apparel" discount "13.5" rating "3.3" +HSET product:30 name "Product-30" price "122.5" quantity "1" category "Home" discount "15.0" rating "3.6" +HSET product:31 name "Product-31" price "125.75" quantity "2" category "Electronics" discount "16.5" rating "3.9" +HSET product:32 name "Product-32" price "129.0" quantity "3" category "Toys" discount "18.0" rating "4.2" +HSET product:33 name "Product-33" price "132.25" quantity "4" category "Electronics" discount "19.5" rating "4.5" +HSET product:34 name "Product-34" price "135.5" quantity "5" category "Home" discount "21.0" rating "4.8" +HSET product:35 name "Product-35" price "138.75" quantity "6" category "Apparel" discount "22.5" rating "3.0" +HSET product:36 name "Product-36" price "142.0" quantity "7" category "Home" discount "24.0" rating "3.3" +HSET product:37 name "Product-37" price "145.25" quantity "8" category "Apparel" discount "25.5" rating "3.6" +HSET product:38 name "Product-38" price "148.5" quantity "9" category "Toys" discount "27.0" rating "3.9" +HSET product:39 name "Product-39" price "151.75" quantity "10" category "Home" discount "28.5" rating "4.2" +HSET product:40 name "Product-40" price "155.0" quantity "1" category "Groceries" discount "0.0" rating "4.5" +HSET product:41 name "Product-41" price "158.25" quantity "2" category "Apparel" discount "1.5" rating "4.8" +HSET product:42 name "Product-42" price "161.5" quantity "3" category "Home" discount "3.0" rating "3.0" +HSET product:43 name "Product-43" price "164.75" quantity "4" category "Books" discount "4.5" rating "3.3" +HSET product:44 name "Product-44" price "168.0" quantity "5" category "Groceries" discount "6.0" rating "3.6" +HSET product:45 name "Product-45" price "171.25" quantity "6" category "Books" discount "7.5" rating "3.9" +HSET product:46 name "Product-46" price "174.5" quantity "7" category "Books" discount "9.0" rating "4.2" +HSET product:47 name "Product-47" price "177.75" quantity "8" category "Groceries" discount "10.5" rating "4.5" +HSET product:48 name "Product-48" price "181.0" quantity "9" category "Electronics" discount "12.0" rating "4.8" +HSET product:49 name "Product-49" price "184.25" quantity "10" category "Toys" discount "13.5" rating "3.0" +HSET product:50 name "Product-50" price "187.5" quantity "1" category "Groceries" discount "15.0" rating "3.3" +HSET product:51 name "Product-51" price "190.75" quantity "2" category "Home" discount "16.5" rating "3.6" +HSET product:52 name "Product-52" price "194.0" quantity "3" category "Home" discount "18.0" rating "3.9" +HSET product:53 name "Product-53" price "197.25" quantity "4" category "Apparel" discount "19.5" rating "4.2" +HSET product:54 name "Product-54" price "200.5" quantity "5" category "Apparel" discount "21.0" rating "4.5" +HSET product:55 name "Product-55" price "203.75" quantity "6" category "Apparel" discount "22.5" rating "4.8" +HSET product:56 name "Product-56" price "207.0" quantity "7" category "Home" discount "24.0" rating "3.0" +HSET product:57 name "Product-57" price "210.25" quantity "8" category "Home" discount "25.5" rating "3.3" +HSET product:58 name "Product-58" price "213.5" quantity "9" category "Books" discount "27.0" rating "3.6" +HSET product:59 name "Product-59" price "216.75" quantity "10" category "Home" discount "28.5" rating "3.9" +HSET product:60 name "Product-60" price "220.0" quantity "1" category "Books" discount "0.0" rating "4.2" +HSET product:61 name "Product-61" price "223.25" quantity "2" category "Toys" discount "1.5" rating "4.5" +HSET product:62 name "Product-62" price "226.5" quantity "3" category "Groceries" discount "3.0" rating "4.8" +HSET product:63 name "Product-63" price "229.75" quantity "4" category "Apparel" discount "4.5" rating "3.0" +HSET product:64 name "Product-64" price "233.0" quantity "5" category "Home" discount "6.0" rating "3.3" +HSET product:65 name "Product-65" price "236.25" quantity "6" category "Apparel" discount "7.5" rating "3.6" +HSET product:66 name "Product-66" price "239.5" quantity "7" category "Apparel" discount "9.0" rating "3.9" +HSET product:67 name "Product-67" price "242.75" quantity "8" category "Apparel" discount "10.5" rating "4.2" +HSET product:68 name "Product-68" price "246.0" quantity "9" category "Groceries" discount "12.0" rating "4.5" +HSET product:69 name "Product-69" price "249.25" quantity "10" category "Toys" discount "13.5" rating "4.8" +HSET product:70 name "Product-70" price "252.5" quantity "1" category "Toys" discount "15.0" rating "3.0" +HSET product:71 name "Product-71" price "255.75" quantity "2" category "Books" discount "16.5" rating "3.3" +HSET product:72 name "Product-72" price "259.0" quantity "3" category "Groceries" discount "18.0" rating "3.6" +HSET product:73 name "Product-73" price "262.25" quantity "4" category "Groceries" discount "19.5" rating "3.9" +HSET product:74 name "Product-74" price "265.5" quantity "5" category "Home" discount "21.0" rating "4.2" +HSET product:75 name "Product-75" price "268.75" quantity "6" category "Groceries" discount "22.5" rating "4.5" +HSET product:76 name "Product-76" price "272.0" quantity "7" category "Apparel" discount "24.0" rating "4.8" +HSET product:77 name "Product-77" price "275.25" quantity "8" category "Groceries" discount "25.5" rating "3.0" +HSET product:78 name "Product-78" price "278.5" quantity "9" category "Electronics" discount "27.0" rating "3.3" +HSET product:79 name "Product-79" price "281.75" quantity "10" category "Books" discount "28.5" rating "3.6" +HSET product:80 name "Product-80" price "285.0" quantity "1" category "Apparel" discount "0.0" rating "3.9" +HSET product:81 name "Product-81" price "288.25" quantity "2" category "Electronics" discount "1.5" rating "4.2" +HSET product:82 name "Product-82" price "291.5" quantity "3" category "Home" discount "3.0" rating "4.5" +HSET product:83 name "Product-83" price "294.75" quantity "4" category "Electronics" discount "4.5" rating "4.8" +HSET product:84 name "Product-84" price "298.0" quantity "5" category "Groceries" discount "6.0" rating "3.0" +HSET product:85 name "Product-85" price "301.25" quantity "6" category "Groceries" discount "7.5" rating "3.3" +HSET product:86 name "Product-86" price "304.5" quantity "7" category "Electronics" discount "9.0" rating "3.6" +HSET product:87 name "Product-87" price "307.75" quantity "8" category "Groceries" discount "10.5" rating "3.9" +HSET product:88 name "Product-88" price "311.0" quantity "9" category "Groceries" discount "12.0" rating "4.2" +HSET product:89 name "Product-89" price "314.25" quantity "10" category "Groceries" discount "13.5" rating "4.5" +HSET product:90 name "Product-90" price "317.5" quantity "1" category "Electronics" discount "15.0" rating "4.8" +HSET product:91 name "Product-91" price "320.75" quantity "2" category "Apparel" discount "16.5" rating "3.0" +HSET product:92 name "Product-92" price "324.0" quantity "3" category "Groceries" discount "18.0" rating "3.3" +HSET product:93 name "Product-93" price "327.25" quantity "4" category "Home" discount "19.5" rating "3.6" +HSET product:94 name "Product-94" price "330.5" quantity "5" category "Groceries" discount "21.0" rating "3.9" +HSET product:95 name "Product-95" price "333.75" quantity "6" category "Groceries" discount "22.5" rating "4.2" +HSET product:96 name "Product-96" price "337.0" quantity "7" category "Groceries" discount "24.0" rating "4.5" +HSET product:97 name "Product-97" price "340.25" quantity "8" category "Apparel" discount "25.5" rating "4.8" +HSET product:98 name "Product-98" price "343.5" quantity "9" category "Apparel" discount "27.0" rating "3.0" +HSET product:99 name "Product-99" price "346.75" quantity "10" category "Home" discount "28.5" rating "3.3" +HSET product:100 name "Product-100" price "350.0" quantity "1" category "Home" discount "0.0" rating "3.6" +HSET product:101 name "Product-101" price "353.25" quantity "2" category "Apparel" discount "1.5" rating "3.9" +HSET product:102 name "Product-102" price "356.5" quantity "3" category "Electronics" discount "3.0" rating "4.2" +HSET product:103 name "Product-103" price "359.75" quantity "4" category "Toys" discount "4.5" rating "4.5" +HSET product:104 name "Product-104" price "363.0" quantity "5" category "Electronics" discount "6.0" rating "4.8" +HSET product:105 name "Product-105" price "366.25" quantity "6" category "Home" discount "7.5" rating "3.0" +HSET product:106 name "Product-106" price "369.5" quantity "7" category "Electronics" discount "9.0" rating "3.3" +HSET product:107 name "Product-107" price "372.75" quantity "8" category "Toys" discount "10.5" rating "3.6" +HSET product:108 name "Product-108" price "376.0" quantity "9" category "Groceries" discount "12.0" rating "3.9" +HSET product:109 name "Product-109" price "379.25" quantity "10" category "Groceries" discount "13.5" rating "4.2" +HSET product:110 name "Product-110" price "382.5" quantity "1" category "Electronics" discount "15.0" rating "4.5" +HSET product:111 name "Product-111" price "385.75" quantity "2" category "Toys" discount "16.5" rating "4.8" +HSET product:112 name "Product-112" price "389.0" quantity "3" category "Apparel" discount "18.0" rating "3.0" +HSET product:113 name "Product-113" price "392.25" quantity "4" category "Books" discount "19.5" rating "3.3" +HSET product:114 name "Product-114" price "395.5" quantity "5" category "Apparel" discount "21.0" rating "3.6" +HSET product:115 name "Product-115" price "398.75" quantity "6" category "Apparel" discount "22.5" rating "3.9" +HSET product:116 name "Product-116" price "402.0" quantity "7" category "Books" discount "24.0" rating "4.2" +HSET product:117 name "Product-117" price "405.25" quantity "8" category "Toys" discount "25.5" rating "4.5" +HSET product:118 name "Product-118" price "408.5" quantity "9" category "Groceries" discount "27.0" rating "4.8" +HSET product:119 name "Product-119" price "411.75" quantity "10" category "Apparel" discount "28.5" rating "3.0" +HSET product:120 name "Product-120" price "415.0" quantity "1" category "Electronics" discount "0.0" rating "3.3" +HSET product:121 name "Product-121" price "418.25" quantity "2" category "Toys" discount "1.5" rating "3.6" +HSET product:122 name "Product-122" price "421.5" quantity "3" category "Home" discount "3.0" rating "3.9" +HSET product:123 name "Product-123" price "424.75" quantity "4" category "Groceries" discount "4.5" rating "4.2" +HSET product:124 name "Product-124" price "428.0" quantity "5" category "Books" discount "6.0" rating "4.5" +HSET product:125 name "Product-125" price "431.25" quantity "6" category "Home" discount "7.5" rating "4.8" +HSET product:126 name "Product-126" price "434.5" quantity "7" category "Toys" discount "9.0" rating "3.0" +HSET product:127 name "Product-127" price "437.75" quantity "8" category "Groceries" discount "10.5" rating "3.3" +HSET product:128 name "Product-128" price "441.0" quantity "9" category "Groceries" discount "12.0" rating "3.6" +HSET product:129 name "Product-129" price "444.25" quantity "10" category "Home" discount "13.5" rating "3.9" +HSET product:130 name "Product-130" price "447.5" quantity "1" category "Electronics" discount "15.0" rating "4.2" +HSET product:131 name "Product-131" price "450.75" quantity "2" category "Apparel" discount "16.5" rating "4.5" +HSET product:132 name "Product-132" price "454.0" quantity "3" category "Toys" discount "18.0" rating "4.8" +HSET product:133 name "Product-133" price "457.25" quantity "4" category "Toys" discount "19.5" rating "3.0" +HSET product:134 name "Product-134" price "460.5" quantity "5" category "Electronics" discount "21.0" rating "3.3" +HSET product:135 name "Product-135" price "463.75" quantity "6" category "Toys" discount "22.5" rating "3.6" +HSET product:136 name "Product-136" price "467.0" quantity "7" category "Groceries" discount "24.0" rating "3.9" +HSET product:137 name "Product-137" price "470.25" quantity "8" category "Groceries" discount "25.5" rating "4.2" +HSET product:138 name "Product-138" price "473.5" quantity "9" category "Apparel" discount "27.0" rating "4.5" +HSET product:139 name "Product-139" price "476.75" quantity "10" category "Toys" discount "28.5" rating "4.8" +HSET product:140 name "Product-140" price "480.0" quantity "1" category "Groceries" discount "0.0" rating "3.0" +HSET product:141 name "Product-141" price "483.25" quantity "2" category "Apparel" discount "1.5" rating "3.3" +HSET product:142 name "Product-142" price "486.5" quantity "3" category "Groceries" discount "3.0" rating "3.6" +HSET product:143 name "Product-143" price "489.75" quantity "4" category "Groceries" discount "4.5" rating "3.9" +HSET product:144 name "Product-144" price "493.0" quantity "5" category "Electronics" discount "6.0" rating "4.2" +HSET product:145 name "Product-145" price "496.25" quantity "6" category "Groceries" discount "7.5" rating "4.5" +HSET product:146 name "Product-146" price "499.5" quantity "7" category "Groceries" discount "9.0" rating "4.8" +HSET product:147 name "Product-147" price "502.75" quantity "8" category "Groceries" discount "10.5" rating "3.0" +HSET product:148 name "Product-148" price "506.0" quantity "9" category "Home" discount "12.0" rating "3.3" +HSET product:149 name "Product-149" price "509.25" quantity "10" category "Electronics" discount "13.5" rating "3.6" +HSET product:150 name "Product-150" price "512.5" quantity "1" category "Electronics" discount "15.0" rating "3.9" +HSET product:151 name "Product-151" price "515.75" quantity "2" category "Books" discount "16.5" rating "4.2" +HSET product:152 name "Product-152" price "519.0" quantity "3" category "Toys" discount "18.0" rating "4.5" +HSET product:153 name "Product-153" price "522.25" quantity "4" category "Toys" discount "19.5" rating "4.8" +HSET product:154 name "Product-154" price "525.5" quantity "5" category "Home" discount "21.0" rating "3.0" +HSET product:155 name "Product-155" price "528.75" quantity "6" category "Home" discount "22.5" rating "3.3" +HSET product:156 name "Product-156" price "532.0" quantity "7" category "Books" discount "24.0" rating "3.6" +HSET product:157 name "Product-157" price "535.25" quantity "8" category "Groceries" discount "25.5" rating "3.9" +HSET product:158 name "Product-158" price "538.5" quantity "9" category "Groceries" discount "27.0" rating "4.2" +HSET product:159 name "Product-159" price "541.75" quantity "10" category "Apparel" discount "28.5" rating "4.5" +HSET product:160 name "Product-160" price "545.0" quantity "1" category "Home" discount "0.0" rating "4.8" +HSET product:161 name "Product-161" price "548.25" quantity "2" category "Home" discount "1.5" rating "3.0" +HSET product:162 name "Product-162" price "551.5" quantity "3" category "Apparel" discount "3.0" rating "3.3" +HSET product:163 name "Product-163" price "554.75" quantity "4" category "Electronics" discount "4.5" rating "3.6" +HSET product:164 name "Product-164" price "558.0" quantity "5" category "Toys" discount "6.0" rating "3.9" +HSET product:165 name "Product-165" price "561.25" quantity "6" category "Home" discount "7.5" rating "4.2" +HSET product:166 name "Product-166" price "564.5" quantity "7" category "Electronics" discount "9.0" rating "4.5" +HSET product:167 name "Product-167" price "567.75" quantity "8" category "Home" discount "10.5" rating "4.8" +HSET product:168 name "Product-168" price "571.0" quantity "9" category "Electronics" discount "12.0" rating "3.0" +HSET product:169 name "Product-169" price "574.25" quantity "10" category "Electronics" discount "13.5" rating "3.3" +HSET product:170 name "Product-170" price "577.5" quantity "1" category "Electronics" discount "15.0" rating "3.6" +HSET product:171 name "Product-171" price "580.75" quantity "2" category "Apparel" discount "16.5" rating "3.9" +HSET product:172 name "Product-172" price "584.0" quantity "3" category "Electronics" discount "18.0" rating "4.2" +HSET product:173 name "Product-173" price "587.25" quantity "4" category "Apparel" discount "19.5" rating "4.5" +HSET product:174 name "Product-174" price "590.5" quantity "5" category "Electronics" discount "21.0" rating "4.8" +HSET product:175 name "Product-175" price "593.75" quantity "6" category "Home" discount "22.5" rating "3.0" +HSET product:176 name "Product-176" price "597.0" quantity "7" category "Toys" discount "24.0" rating "3.3" +HSET product:177 name "Product-177" price "600.25" quantity "8" category "Toys" discount "25.5" rating "3.6" +HSET product:178 name "Product-178" price "603.5" quantity "9" category "Apparel" discount "27.0" rating "3.9" +HSET product:179 name "Product-179" price "606.75" quantity "10" category "Toys" discount "28.5" rating "4.2" +HSET product:180 name "Product-180" price "610.0" quantity "1" category "Toys" discount "0.0" rating "4.5" +HSET product:181 name "Product-181" price "613.25" quantity "2" category "Books" discount "1.5" rating "4.8" +HSET product:182 name "Product-182" price "616.5" quantity "3" category "Home" discount "3.0" rating "3.0" +HSET product:183 name "Product-183" price "619.75" quantity "4" category "Books" discount "4.5" rating "3.3" +HSET product:184 name "Product-184" price "623.0" quantity "5" category "Groceries" discount "6.0" rating "3.6" +HSET product:185 name "Product-185" price "26.25" quantity "6" category "Groceries" discount "7.5" rating "3.9" +HSET product:186 name "Product-186" price "29.5" quantity "7" category "Electronics" discount "9.0" rating "4.2" +HSET product:187 name "Product-187" price "32.75" quantity "8" category "Apparel" discount "10.5" rating "4.5" +HSET product:188 name "Product-188" price "36.0" quantity "9" category "Groceries" discount "12.0" rating "4.8" +HSET product:189 name "Product-189" price "39.25" quantity "10" category "Toys" discount "13.5" rating "3.0" +HSET product:190 name "Product-190" price "42.5" quantity "1" category "Home" discount "15.0" rating "3.3" +HSET product:191 name "Product-191" price "45.75" quantity "2" category "Groceries" discount "16.5" rating "3.6" +HSET product:192 name "Product-192" price "49.0" quantity "3" category "Groceries" discount "18.0" rating "3.9" +HSET product:193 name "Product-193" price "52.25" quantity "4" category "Books" discount "19.5" rating "4.2" +HSET product:194 name "Product-194" price "55.5" quantity "5" category "Apparel" discount "21.0" rating "4.5" +HSET product:195 name "Product-195" price "58.75" quantity "6" category "Home" discount "22.5" rating "4.8" +HSET product:196 name "Product-196" price "62.0" quantity "7" category "Home" discount "24.0" rating "3.0" +HSET product:197 name "Product-197" price "65.25" quantity "8" category "Apparel" discount "25.5" rating "3.3" +HSET product:198 name "Product-198" price "68.5" quantity "9" category "Electronics" discount "27.0" rating "3.6" +HSET product:199 name "Product-199" price "71.75" quantity "10" category "Groceries" discount "28.5" rating "3.9" +HSET product:200 name "Product-200" price "75.0" quantity "1" category "Toys" discount "0.0" rating "4.2" diff --git a/content/develop/interact/search-and-query/advanced-concepts/stopwords.md b/content/develop/interact/search-and-query/advanced-concepts/stopwords.md index c93bdb4c60..b586a2e006 100644 --- a/content/develop/interact/search-and-query/advanced-concepts/stopwords.md +++ b/content/develop/interact/search-and-query/advanced-concepts/stopwords.md @@ -12,7 +12,7 @@ categories: description: Stop words support linkTitle: Stop words title: Stop words -weight: 1 +weight: 2 --- Redis Open Source has a default list of [stop words](https://en.wikipedia.org/wiki/Stop_words). These are words that are usually so common that they do not add much information to search, but take up a lot of space and CPU time in the index.