Skip to content

Commit bc5ae2e

Browse files
add example and clean up
1 parent 1e75deb commit bc5ae2e

File tree

7 files changed

+35
-713
lines changed

7 files changed

+35
-713
lines changed

modules/ROOT/content-nav.adoc

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,6 @@
3737
** xref:clauses/where.adoc[]
3838
** xref:clauses/with.adoc[]
3939
40-
* xref:expressions/index.adoc[]
41-
** xref:expressions/expressions-overview.adoc[]
42-
** xref:expressions/predicates/index.adoc[]
43-
*** xref:expressions/predicates/boolean-operators.adoc[]
44-
*** xref:expressions/predicates/comparison-operators.adoc[]
45-
*** xref:expressions/predicates/list-operators.adoc[]
46-
*** xref:expressions/predicates/string-operators.adoc[]
47-
*** xref:expressions/predicates/path-pattern-expressions.adoc[]
48-
*** xref:expressions/predicates/type-predicate-expressions.adoc[]
49-
** xref:expressions/conditional-expressions.adoc[]
50-
5140
* xref:subqueries/index.adoc[]
5241
** xref:subqueries/call-subquery.adoc[]
5342
** xref:subqueries/subqueries-in-transactions.adoc[]
@@ -63,7 +52,6 @@
6352
** xref:patterns/non-linear-patterns.adoc[]
6453
** xref:patterns/reference.adoc[]
6554
66-
6755
* xref:values-and-types/index.adoc[]
6856
** xref:values-and-types/property-structural-constructed.adoc[]
6957
** xref:values-and-types/temporal.adoc[]
@@ -74,11 +62,13 @@
7462
** xref:values-and-types/casting-data.adoc[]
7563
** xref:values-and-types/ordering-equality-comparison.adoc[]
7664
77-
7865
* xref:expressions/index.adoc[]
7966
** xref:expressions/expressions-overview.adoc[]
8067
** xref:expressions/predicates/index.adoc[]
81-
*** xref:expressions/predicates/operators.adoc[]
68+
*** xref:expressions/predicates/boolean-operators.adoc[]
69+
*** xref:expressions/predicates/comparison-operators.adoc[]
70+
*** xref:expressions/predicates/list-operators.adoc[]
71+
*** xref:expressions/predicates/string-operators.adoc[]
8272
*** xref:expressions/predicates/path-pattern-expressions.adoc[]
8373
*** xref:expressions/predicates/type-predicate-expressions.adoc[]
8474
** xref:expressions/conditional-expressions.adoc[]
@@ -101,7 +91,6 @@
10191
** xref:functions/user-defined.adoc[]
10292
** xref:functions/vector.adoc[]
10393
104-
10594
* xref:genai-integrations.adoc[]
10695
* xref:indexes/index.adoc[]
10796
** xref:indexes/search-performance-indexes/overview.adoc[]

modules/ROOT/pages/expressions/expressions-overview.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ For more information, see xref:clauses/where.adoc#filter-on-dynamic-property[`WH
1818
* A xref:patterns/fixed-length-patterns.adoc#path-patterns[path-pattern]: `+(a)-[r]->(b)+`, `+(a)-[r]-(b)+`, `+(a)--(b)+`, `+(a)-->()<--(b)+`.
1919
* An xref:syntax/operators.adoc[operator application]: `1 + 2`, `3 < 4`.
2020
* A xref:subqueries/index.adoc[subquery expression]: `COUNT {}`, `COLLECT {}`, `EXISTS {}`, `CALL {}`.
21-
* A xref:expressions/predicates/operators#regular-expressions[regular expression]: `a.name =~ 'Tim.*'`.
21+
* A xref:expressions/predicates/string-operators#regular-expressions[regular expression]: `a.name =~ 'Tim.*'`.
2222
* A xref:expressions/conditional-expressions.adoc[`CASE` expression].
2323
* xref:values-and-types/working-with-null[`null`].
2424

modules/ROOT/pages/expressions/predicates/list-operators.adoc

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,33 @@ RETURN p.name AS name, p.role AS role
7777
2+d|Rows: 3
7878
|===
7979
80+
The below query finds `Person` nodes that share the `role` of `Cecil` or `Eskil` but have a different `name`.
81+
82+
.Multiple `IN` operators
83+
[source, cypher]
84+
----
85+
WITH ['Cecil', 'Eskil'] AS names
86+
MATCH (ce:Person)
87+
WHERE ce.name IN names
88+
WITH collect(ce.role) AS roles, names
89+
MATCH (p:Person)
90+
WHERE p.role IN roles AND NOT p.name IN names
91+
RETURN p.name AS name, p.role AS role
92+
----
93+
94+
Only `Cecilia` is returned because she shares a `role` with `Cecil` (no `Person` node in the graph shares a `role` with `Eskil`).
95+
96+
.Result
97+
[role="queryresult",options="header,footer",cols="2*<m"]
98+
|===
99+
| name | role
100+
101+
| "Cecilia" | "Software developer"
102+
103+
2+d|Rows: 1
104+
|===
105+
106+
80107
=====
81108

82109
.Checking membership in `LIST` values containing duplicates

0 commit comments

Comments
 (0)