Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
06-07-2021 02:15 PM
match (n:invt{cui:"Cxxxxxxx"}), (m:dsyn{cui:"Cyyyyyyy"})
Using Index n:invt(cui)
Using index m:dsyn(cui)
with n, collect(m) as terminatorNodes
CALL apoc.path.expandConfig(n, {
relationshipFilter:"
causes_f3plus>",
minLevel: 1,
maxLevel: 5,
terminatorNodes:terminatorNodes,
uniqueness: "NODE_PATH"
})
yield path
return count(path), length(path)
06-07-2021 02:19 PM
match (n:Concept{cui:"Cxxxxxxx"}), (m:Concept{cui:"Cyyyyyyyy"})
with n,m
match path=(n)-[r:causes_f3plus*1..5]->(m)
return count(DISTINCT(path))
//The where clause was a error in the previous comment but the issue still stands.
06-07-2021 02:40 PM
Hello,
You need to provide more context here. We don't know which of the two queries you provided is giving the "wrong" results, and you've only showed us two approaches connecting two nodes (I'm assuming your A to Z in your example), you haven't shown us the queries showing A to B and B to Z. Please add more context to what you've provided, especially the results associated with each query.
All the sessions of the conference are now available online