You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
All of these clauses _must_ match. The equivalent of `AND`.
38
-
39
-
`must_not`::
40
-
All of these clauses _must not_ match. The equivalent of `NOT`.
41
-
42
-
`should`::
43
-
At least one of these clauses must match. The equivalent of `OR`.
32
+
`must`::
33
+
所有的语句都 _必须(must)_ 匹配,与 `AND` 等价。
44
34
45
-
And that's it!((("should clause", "in bool filters")))((("must_not clause", "in bool filters")))((("must clause", "in bool filters"))) When you need multiple filters, simply place them into the
46
-
different sections of the `bool` filter.
35
+
`must_not`::
36
+
所有的语句都 _不能(must not)_ 匹配,与 `NOT` 等价。
37
+
38
+
`should`::
39
+
至少有一个语句要匹配,与 `OR` 等价。
40
+
41
+
就这么简单!((("should clause", "in bool filters")))((("must_not clause", "in bool filters")))((("must clause", "in bool filters"))) 当我们需要多个过滤器时,只须将它们置入 `bool` 过滤器的不同部分即可。
47
42
48
43
[NOTE]
49
44
====
50
-
Each section of the `bool` filter is optional (for example, you can have a `must`
51
-
clause and nothing else), and each section can contain a single filter or an
To replicate the preceding SQL example, we will take the two `term` filters that
56
-
we used((("term filter", "placing inside bool filter")))((("bool filter", "with two term filters in should clause and must_not clause"))) previously and place them inside the `should` clause of a `bool`
57
-
filter, and add another clause to deal with the `NOT` condition:
Even though `bool` is a compound filter and accepts children filters, it is
118
-
important to understand that `bool` is just a filter itself.((("filters", "combining", "nesting bool filters")))((("bool filter", "nesting in another bool filter"))) This means you
119
-
can nest `bool` filters inside other `bool` filters, giving you the
120
-
ability to make arbitrarily complex Boolean logic.
105
+
尽管 `bool` 是一个复合的过滤器,可以接受多个子过滤器,需要注意的是 `bool` 过滤器本身仍然还只是一个过滤器。((("filters", "combining", "nesting bool filters")))((("bool filter", "nesting in another bool filter"))) 这意味着我们可以将一个 `bool` 过滤器置于其他 `bool` 过滤器内部,这为我们提供了对任意复杂布尔逻辑进行处理的能力。
0 commit comments