Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
01-16-2022 02:14 AM
Hi everyone
How can I write a function in neo4j that takes each person's name as input and output that person's relationships with other people in different files?
01-16-2022 08:05 AM
Can you clarify your requirements so we can help?
In the meantime, the following cypher will get all the people a person knows, where the people are provided in a list. Maybe this helps getting you started.
with ['John', 'Sally', 'Paul'] as names
unwind names as name
match (n:Person{name:name})-[:KNOWS]->(m)
return n as person, collect(m) as knows
Test Data:
Result:
All the sessions of the conference are now available online