Guest User

Untitled

a guest
Feb 16th, 2019
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. // returns a single node of any type (limited to 1 for performance)
  2. MATCH (a) RETURN a LIMIT 1
  3.  
  4. // returns a single node of type Author
  5. MATCH (a:Author) RETURN a LIMIT 1
  6.  
  7. // returns the path between 10 Author/Paper nodes
  8. MATCH path=((a:Author)->(p:Paper)) RETURN path LIMIT 10
  9.  
  10. // returns a nodes of type Author and Paper with edge type specified
  11. MATCH (a:Author)-[:AUTHORS]->(p:Paper) RETURN * LIMIT 10
  12.  
  13. // returns 10 Author nodes that were the first author on a Paper
  14. // Note that querying on edge properties is very expensive
  15. MATCH (a:Author)-[auth:AUTHORS {position: 1}]->(p:Paper) RETURN a LIMIT 10
  16.  
  17. // returns Author nodes with the last name 'Berendse'
  18. MATCH (a:Author {last: 'Berendse'}) RETURN *
Add Comment
Please, Sign In to add comment