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
Copy file name to clipboardexpand all lines: cip/1.accepted/CIP2017-06-18-multiple-graphs.adoc
+16-15
Original file line number
Diff line number
Diff line change
@@ -50,7 +50,7 @@ This CIP has been developed in tandem with the following CIPs; as such, it is re
50
50
51
51
* `CIP2016-06-22`: Nested subqueries
52
52
* `CIP2018-05-04`: Equivalence operators, copy pattern, and related auxiliary functions
53
-
* `CIP2018-05-03`: Creating and administrating graphs and views
53
+
* `CIP2018-05-03`: Creating and administering graphs and views
54
54
55
55
56
56
== The data model
@@ -99,8 +99,8 @@ A _**relationship type**_ is a name used to classify a relationship.
99
99
100
100
.Definition 6
101
101
A _**value**_ is any value that is supported by the Cypher type system.
102
-
A _**scalar value**_ is any opaque value that cannot be further divided into multiple constituting values.
103
-
A _**nested value**_ is any value that is composed of multiple constituting values.
102
+
A _**scalar value**_ is any opaque value that cannot be sub-divided into multiple constituent values.
103
+
A _**nested value**_ is any value that is composed of multiple values.
104
104
105
105
.Definition 7
106
106
A _**property**_ is a tuple consisting of a name (called the _**property key**_) and a value (called the _**property value**_).
@@ -121,10 +121,10 @@ A relationship contains a start node and an end node (both drawn from the same g
121
121
We note that the start and end nodes may be the same node, hence denoting a https://en.wikipedia.org/wiki/Loop_(graph_theory)[self-loop] relationship.
122
122
123
123
.Definition 11
124
-
The _**contents**_ of a model element are its constituents but not its identity.
125
-
For a node (respectively relationship) this comprises its labels, and properties (respectively, its relationship type, properties, as well as its start node and its end node).
126
-
The _**plain contents**_ of a mode element is the same as the contents of the model element but excludes the identity of the start node and the end node of relationships.
127
-
The _**shallow contenst**_ of a mode element is the same as the contents of the model element but excludes the start node and the end node of relationships.
124
+
The _**contents**_ of a model element include its constituents but not its identity.
125
+
For a node (respectively relationship) this comprises its labels, and properties (respectively, its relationship type, properties, as well as its start node and its end node, the latter defined recursively).
126
+
The _**plain contents**_ of a model element is the same as the contents of the model element but excludes the identity of the start node and the end node of relationships. XXTODOXXX
127
+
The _**shallow contenst**_ of a model element is the same as the contents of the model element but excludes the start node and the end node of relationships.
128
128
129
129
130
130
.Definition 12
@@ -179,13 +179,13 @@ The set of *atoms* of an arbitrary value `v` is a list of all scalar values cont
179
179
180
180
A *valid* multiple property graph model instance adheres to the following restrictions:
181
181
182
-
* The atoms of an identity value of any model element must not contain `NULL`.
182
+
* The atoms of an identity value of any model element must not contain `NULL`. XXWHERE-is-identity-value-defined???
183
183
* The atoms of an identity value of any model element must not contain a reference to a model element.
184
184
* Property values must not be `NULL`
185
-
(Note that this differs from an entity not having a property key).
185
+
(Note that this differs from an entity not having some property key `key`).
186
186
* The atoms of any property value of any entity must not contain a reference to a model element.
187
187
188
-
Note:: Without these restrictions, nodes could be used to as part of graph identities and relationships could be used as property values.
188
+
Note:: Without these restrictions, nodes could be used to form part of graph identities, and relationships could be used as property values.
189
189
190
190
191
191
== Query structure
@@ -202,7 +202,7 @@ Note:: As per this and all accompanying proposals, the list of current and propo
202
202
`THEN` is not considered to be an operator clause.
203
203
204
204
.Definition 22
205
-
A _**simple clause chain**_ is a sequence of one or more non-operator clauses which each may be further qualified by clause arguments, sub-clauses and sub-clause arguments.
205
+
A _**simple clause chain**_ is a sequence of one or more non-operator clauses which may each be further qualified by clause arguments, sub-clauses and sub-clause arguments.
206
206
207
207
.Definition 23
208
208
An _**operator clause chain**_ comprises two or more simple clause chains that are separated by the same operator clause.
@@ -359,7 +359,7 @@ Note:: As a consequence, the same identity value may refer to different model el
359
359
360
360
The client always receives the current contents of all returned model elements:
361
361
362
-
1. If an execution result that is returned _to the client_ is a graph result, the contents of this graph is returned.
362
+
1. If an execution result that is returned _to the client_ is a graph result, the contents of this graph is returned.XXXSLOPPY
363
363
364
364
2. If an execution result that is returned _to the client_ is a tabular, the contents and identity of all contained entities is returned.
365
365
@@ -431,7 +431,7 @@ An error is raised in these scenarios:
431
431
* `< graph-name >` is not the name of a graph in the catalog.
432
432
* Attempting to perform an updating operation on a working graph introduced using `FROM [GRAPH]`.
433
433
434
-
Note:: A subquery form of `FROM` is proposed in the accompanying `CIP2018-05-03`.
434
+
Note:: A subquery form of `FROM` is proposed in the accompanying CIP `CIP2018-05-03: Nested subqueries`.
435
435
436
436
437
437
=== Selecting the working graph from the catalog: updating
@@ -453,7 +453,7 @@ An error is raised in these scenarios:
453
453
* `< graph-name >` is not the name of a graph in the catalog.
454
454
* If no updating operations are performed on a working graph that was introduced using `UPDATE [GRAPH]`.
455
455
456
-
Note:: A subquery form of `UPDATE` is proposed in the accompanying `CIP2018-05-03`.
456
+
Note:: A subquery form of `UPDATE` is proposed in the accompanying CIP `CIP2018-05-03: Nested subqueries`.
457
457
458
458
459
459
=== Using the working graph when interpreting a pattern
@@ -466,7 +466,7 @@ Consider the following example:
466
466
467
467
[source, cypher]
468
468
----
469
-
UDPATE graph1
469
+
UPDATE graph1
470
470
CREATE (a)
471
471
WITH *
472
472
FROM graph2
@@ -475,6 +475,7 @@ RETURN count(*) AS count
475
475
----
476
476
477
477
This will always return a count of zero since the `MATCH` clause cannot possibly find any node in `graph2` that is identical to `(a)` even though `graph2` may very well contain nodes `(b)`.
478
+
XXMORE-needs-to-be-said.What about WITH *xxxx
478
479
479
480
An error is raised if a statement attempts to update an entity that is not contained in the working graph.
0 commit comments