I do have relationship like following, through my Cypher query I'm beginning with Segment1
and getting relationships accordingly.
(Segment1)-[:Leaf]->(Op1)-[:Account]->(Ac2)-[:Parent]->(Acc1)-[:Parent]->(Acc)
I want to get the top most node of [:Parent]
relationship hierarchy. Is there any way to obtain it?
Note: I need obtain this without using loops in Cypher because this is only a part of my query.
Expected Output
(Acc)
Please help me to figure out this