Created
April 4, 2021 17:29
-
-
Save damoahdominic/8fbb3f9db6cc5d8140b5964abf343a19 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JSON Data Structure Representation | |
var nodes = [ | |
{ | |
id: 1, | |
labels: ["District"] | |
}, | |
{ | |
id: 2, | |
labels: ["Student"] | |
} | |
] | |
var edges = [ | |
{ | |
source: 1, | |
destination: 2 | |
}, | |
{ | |
source: 2, | |
destination: 1 | |
}, | |
{ | |
source: 2, | |
destination: 2 | |
}, | |
] | |
Algo Starts Here | |
------- | |
Nodes | |
------- | |
N1 | |
N2 | |
N3 | |
N4 | |
N5 | |
N6 | |
Edges | |
--------- | |
N1 -> N2 | |
N1 -> N3 | |
N1 -> N4 | |
N1 -> N5 | |
N1 -> N6 | |
Incoming | |
---------- | |
N1 = 0 | |
N2 = 2 | |
Outgoing | |
---------- | |
N1 = 5 | |
N2 = 1 | |
(N2)<-(N1)->(N3) [DOUBLE] | |
(N4)<-(N1)->(N5) [DOUBLE] | |
(N6)<-(N1) [SINGLE] | |
Fragments | |
[ | |
(N2)<-(N1)->(N3) [DOUBLE] | |
(N4)<-(N1)->(N5) [DOUBLE] | |
(N2)<-(N1)->(N3) [DOUBLE] | |
(N4)<-(N1)->(N5) [DOUBLE] | |
(N2)<-(N1)->(N3) [DOUBLE] | |
(N4)<-(N1)->(N5) [DOUBLE] | |
(N2)<-(N1)->(N3) [DOUBLE] | |
(N4)<-(N1)->(N5) [DOUBLE] | |
(N2)<-(N1)->(N3) [DOUBLE] | |
(N4)<-(N1)->(N5) [DOUBLE] | |
(N2)<-(N1)->(N3) [DOUBLE] | |
(N4)<-(N1)->(N5) [DOUBLE] | |
(N6)<-(N1) [SINGLE] | |
(N6)<-(N1) [SINGLE] | |
(N6)<-(N1) [SINGLE] | |
] | |
Combine Fragments (Fragments) | |
Exports Cypher Complaint Query | |
MATCH (N2)<-(N1)->(N3),(N4)<-(N1)->(N5),(N6)<-(N1) [FRAGMENTS_GO_HERE] RETURN * |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment