Skip to content

Commit 40bac1d

Browse files
change arrays to lists
1 parent 55cd133 commit 40bac1d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

modules/ROOT/pages/types/relationships.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,14 +52,14 @@ type Movie @node {
5252
Note that, in this query:
5353

5454
* A `Person` can _act in_ or _direct_ multiple movies, and a `Movie` can have multiple actors.
55-
While it is rare for a `Movie` to have more than one director, Neo4j GraphQL Library requires all relationships to be modeled as "many" relationships (using arrays).
55+
While it is rare for a `Movie` to have more than one director, Neo4j GraphQL Library requires all relationships to be modeled as "many" relationships (using Lists).
5656
* Even conceptually one-to-one relationships like a movie having a single director must be represented as arrays (e.g., `directors: [Person!]!`) because Neo4j cannot reliably enforce 1:1 cardinality between nodes.
5757
* To figure out whether the `direction` argument of the `@relationship` directive should be `IN` or `OUT`, visualize your relationships like in the diagram above, then model out the direction of the arrows.
5858
* The `@relationship` directive is a reference to Neo4j relationships, whereas in the schema, the phrase `edge(s)` is used to be consistent with the general API language used by Relay.
5959

6060
=== Neo4j GraphQL Cardinality Limitation
6161

62-
It's important to understand that Neo4j cannot reliably enforce 1:1 cardinality between nodes in a graph database. Therefore, all relationships in Neo4j GraphQL are modeled as "many" relationships (using arrays) even when conceptually they represent one-to-one relationships.
62+
It's important to understand that Neo4j cannot reliably enforce 1:1 cardinality between nodes in a graph database. Therefore, all relationships in Neo4j GraphQL are modeled as "many" relationships (using Lists) even when conceptually they represent one-to-one relationships.
6363
As alternative you can define your relationship with the `@cypher` directive, however some of the functionality provided by the Neo4j GraphQL Library will not be available.
6464

6565
=== Relationship properties

0 commit comments

Comments
 (0)