Skip to content
Snippets Groups Projects
Commit c8ddf9a2 authored by Sven-Ove Hänsel's avatar Sven-Ove Hänsel
Browse files

update query memgraph to shortest path dfs

parent 1c60e9d4
No related branches found
No related tags found
No related merge requests found
count|MATCH (n) return count(n);
anc|MATCH path=(node:Host)-[*]->(ancestor) RETURN ancestor, size(path) AS distance_upstream ORDER BY distance_upstream;
desc|MATCH path=(node:Host)<-[*]-(descendant) RETURN descendant, size(path) AS distance_downstream ORDER BY distance_downstream;
path|MATCH path = (a {_uuid:'0CF2BB3E-36B8-11E8-BF66-D9AA8AFF4A69'})-[ *bfs]-(b {_uuid:'586C56DA-CB56-745E-96CB-52069E742598'}) RETURN path;
path|MATCH path = ((a {_uuid: 'A6A7C956-0132-5506-96D1-2A7DE97CB400'})-[*ALLSHORTEST(r,n|1)]->(b {_uuid:'8DA367BF-36C2-11E8-BF66-D9AA8AFF4A69'})) RETURN path;
2-hop|MATCH (a) where a._uuid='9FF334BB-9072-D756-B290-556656D73728' CALL neighbors.by_hop(a, [""], 2) YIELD nodes RETURN nodes;
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment