0
votes

if have a graph (maven pom dependency) with 2 nodes type : ARTEFACT and VERSION and 2 relation type : VERSION and PROVIDED

an example of my graph :

ARTEFACT1 ---VERSION---> V_1_20   <---PROVIDED---  ARTEFACT2
                                  <---PROVIDED---  ARTEFACT3
          ---VERSION---> V_1_50   <---PROVIDED--- ARTEFACT4

ARTEFACT5 ---VERSION---> V_1_00   <---PROVIDED--- ARTEFACT6

ARTEFACT7 ---VERSION---> V_2_00

I did find how i can made request to get ARTEFACTs nodes which have more than one VERSION relations which terminal node of the relation have PROVIDED relation.

In my example the request would only return :

ARTEFACT1 ---VERSION---> V_1_20   <---PROVIDED---  ARTEFACT2
                                  <---PROVIDED---  ARTEFACT3
          ---VERSION---> V_1_50   <---PROVIDED--- ARTEFACT4
1
What's your question? - Nicole White

1 Answers

0
votes

Something like this?

match (a:ARTEFACT)-[:VERSION]->(v)-[:PROVIDED]-(p)
with a,count(v) as count
where count > 1
return a

Your question isn't very clear so please add some more details if I've misunderstood