Skip to content

Commit 6f23a4d

Browse files
committed
Review fixes
1 parent 6940e0d commit 6f23a4d

File tree

7 files changed

+41
-7
lines changed

7 files changed

+41
-7
lines changed

modules/ROOT/pages/errors/gql-errors/22NCB.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
= 22NCB
22

33
== Status description
4-
error: data exception - relationship element type already exists. A relationship element type identified by the relationship type `{ <<relType>> }` already exists in the graph type."
4+
error: data exception - relationship element type already exists. A relationship element type identified by the relationship type `{ <<relType>> }` already exists in the graph type.
55

66
== Explanation
77

modules/ROOT/pages/errors/gql-errors/22NCC.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
= 22NCC
22

33
== Status description
4-
error: data exception - node element type specified incorrectly. The node element type identified by the label `{ <<label>> }` is different to the one specified in the query.
4+
error: data exception - node element type specified incorrectly. The node element type `{ <<graphTypeElement>> }` identified by the label `{ <<label>> }` is different to the one specified in the query `{ <<graphTypeElement>> }`.
55

66
== Explanation
77

@@ -28,7 +28,7 @@ The query returns an error with GQLSTATUS 22NCC and the status description:
2828

2929
[source]
3030
----
31-
error: data exception - node element type specified incorrectly. The node element type identified by the label `Person` is different to the one specified in the query.
31+
error: data exception - node element type specified incorrectly. The node element type (`p`:`Person` => {`name` :: STRING }) identified by the label `Person` is different to the one specified in the query (`p`:`Person` => :`Student`).
3232
----
3333

3434
To fix this, change the query as follows:

modules/ROOT/pages/errors/gql-errors/22NCD.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
= 22NCD
22

33
== Status description
4-
error: data exception - relationship element type specified incorrectly. The relationship element type identified by the relationship type `{ <<relType>> }` is different to the one specified in the query.
4+
error: data exception - relationship element type specified incorrectly. The relationship element type `{ <<graphTypeElement>> }` identified by the relationship type `{ <<relType>> }` is different to the one specified in the query `{ <<graphTypeElement>> }`.
55

66
== Explanation
77

@@ -27,7 +27,7 @@ The query returns an error with GQLSTATUS 22NCD and the status description:
2727

2828
[source]
2929
----
30-
error: data exception - relationship element type specified incorrectly. The relationship element type identified by the relationship type `REL` is different to the one specified in the query.
30+
error: data exception - relationship element type specified incorrectly. The relationship element type ()-[r:`REL` => {`name` :: STRING }]->() identified by the relationship type `REL` is different to the one specified in the query ()-[`r`:`REL` => {`name` :: STRING, `age` :: INT }]->().
3131
----
3232

3333
To fix this, change the query as follows:

modules/ROOT/pages/errors/gql-errors/22NCE.adoc

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
= 22NCE
22

33
== Status description
4-
error: data exception - node element type in use. The node element type identified by the label `{ <<label>> }` is referenced in the graph type element '{ <<graphTypeReference>> }' and cannot be dropped.
4+
error: data exception - node element type in use. The node element type identified by the label `{ <<label>> }` is referenced in the graph type element `{ <<graphTypeReference>> }` and cannot be dropped.
55

66
== Explanation
77

@@ -31,10 +31,14 @@ The query returns an error with GQLSTATUS 22NCE and the status description:
3131
error: data exception - node element type in use. The node element type identified by the label `Car` is referenced in the graph type element '()-[:`DRIVES` =>]->()' and cannot be dropped.
3232
----
3333

34-
To fix this, change the query as follows:
34+
To fix this and drop both types, change the query as follows:
3535

3636
[source, cypher]
3737
----
38+
ALTER CURRENT GRAPH TYPE DROP {
39+
(:Person => ),
40+
()-[:DRIVES]->()
41+
}
3842
3943
----
4044

modules/ROOT/pages/errors/gql-errors/22NCF.adoc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@
44
error: data exception - graph type constraint not supported. Graph type constraint definitions are not supported in the `{ <<graphTypeOperation>> }` operation.
55

66
== Explanation
7+
This error occurs when an attempt is made to specify a graph type constraint using the DROP or AMEND operations, which does not support such operations.
8+
Graph type constraints my only be dropped by name when using the DROP operation, and are completely invalid when using AMEND.
9+
This also applies to graph type constraints defined inline of the graph type elements using `IS KEY` and `IS UNIQUE`
710

811
== Example scenario
912

@@ -42,6 +45,7 @@ To fix this, change the query as follows:
4245
ALTER CURRENT GRAPH TYPE DROP {
4346
CONSTRAINT c1
4447
}
48+
4549
ALTER CURRENT GRAPH TYPE ADD {
4650
CONSTRAINT c1 FOR (s:Student) REQUIRE s.studentId :: STRING
4751
}

modules/ROOT/pages/errors/gql-errors/index.adoc

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -687,6 +687,31 @@ Status description:: error: data exception - graph type contains duplicated toke
687687

688688
Status description:: error: data exception - invalid element type constraints in graph type. A `{ <<entityType>>1 }` element type property `{ <<context>> }` constraint cannot be specified inline of a `{ <<entityType>>2 }` element type.
689689

690+
=== xref:errors/gql-errors/22NCA.adoc[22NCA]
691+
692+
Status description:: error: data exception - node element type already exists. A node element type identified by the label `{ <<label>> }` already exists in the graph type.
693+
694+
=== xref:errors/gql-errors/22NCB.adoc[22NCB]
695+
696+
Status description:: error: data exception - relationship element type already exists. A relationship element type identified by the relationship type `{ <<relType>> }` already exists in the graph type.
697+
698+
=== xref:errors/gql-errors/22NCC.adoc[22NCC]
699+
700+
Status description:: error: data exception - node element type specified incorrectly. The node element type `{ <<graphTypeElement1>> }` identified by the label `{ <<label>> }` is different to the one specified in the query `{ <<graphTypeElement2>> }`.
701+
702+
=== xref:errors/gql-errors/22NCD.adoc[22NCD]
703+
704+
Status description:: error: data exception - relationship element type specified incorrectly. The relationship element type `{ <<graphTypeElement1>> }` identified by the relationship type `{ <<relType>> }` is different to the one specified in the query `{ <<graphTypeElement2>> }`.
705+
706+
=== xref:errors/gql-errors/22NCE.adoc[22NCE]
707+
708+
Status description:: error: data exception - node element type in use. The node element type identified by the label `{ <<label>> }` is referenced in the graph type element `{ <<graphTypeReference>> }`` and cannot be dropped.
709+
710+
=== xref:errors/gql-errors/22NCF.adoc[22NCF]
711+
712+
Status description:: error: data exception - graph type constraint not supported. Graph type constraint definitions are not supported in the `{ <<graphTypeOperation>> }` operation.
713+
714+
690715
[[invalid-transaction-state]]
691716
== Invalid transaction state
692717

modules/ROOT/partials/glossary.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
[[funType]]$funType:: Function type, e.g. non-deterministic or aggregate.
4747
[[graph]]$graph:: The name of a graph, for example, `myGraph`.
4848
[[graphTypeDependence]]$graphTypeDependence:: Graph type dependencency for constraint, one of `UNDESIGNATED`, `INDEPENDENT`, or `DEPENDENT`.
49+
[[graphTypeElement]]$graphTypeElement:: An element of a graph type, for example `(:Node => { name :: STRING})`, or `(:Src)-[:REL =>]->(:Target)`.
4950
[[graphTypeReference]]$graphTypeReference:: Graph type reference, for example, `(:Node =>)` or `p`.
5051
[[graphTypeOperation]]$graphTypeOperation:: Graph type operation, for example, one of `SET`, `ADD`, `DROP` or `ALTER`.
5152
[[hint]]$hint:: Freeform description of a hint, for example, `USING INDEX n:N(prop)`.

0 commit comments

Comments
 (0)