Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
02-10-2022 01:36 AM
Hello All ,
I am looking for traversal of nodes on based on the specific node property.
Below is my graph structure and I want to traverse on left or right side based on the specific node
Here if I am filtering out by Node property SS3 , I want to display all the nodes from SS1 till SS3.
I am not able to achieve the same using Cypher , please find the below cypher I have used.
</>
match (n:Schema_Structure{name:'SS3'})
call apoc.path.expandConfig(n,{
relationshipFilter:"Has_Target_SS|Has_Target_Mapping",
minlevel:1,
maxlevel:3,
terminateNode:[n]
})
yield path
return path,length(path) as hops
order by hops;
</>
I tried to change the maxlevel param as well to restrict till SS3 , but its not yielding the desired result.
02-11-2022 08:30 AM
Have you tried something like that first:
match (start:Schema_Structure{name:'SS1'})
match (end:Schema_Structure{name:'SS3'})
match path=(start)-[*]->(end)
return nodes(path)
All the sessions of the conference are now available online