0

We are getting started in Graph databases, and I don't understand how to make a select query where I need to select 5th grade friends of a user foo@hmail.com.

Also I wanted to know if there is some kind of tutorial for this kind of query, because I didn't find one.

howie
  • 2,587
  • 3
  • 27
  • 43
  • 4
    Please see https://stackoverflow.com/help/how-to-ask , and show what your effort so far. Do you try to find it in stackoverflow ,such as https://stackoverflow.com/questions/44743996/neo4j-find-degree-of-connection – howie Apr 13 '19 at 00:52

1 Answers1

0
MATCH (n:User {Name:"foo@hmail.com"})-[:friends]->(a)-[:IN_GRADE]->(g)
WHERE g.grade = 5
RETURN a.Name

I think this is what you are looking for.

Best place to learn : https://neo4j.com/docs/cypher-manual/current/introduction/

krishna reddy
  • 295
  • 2
  • 15