cancel
Showing results for 
Search instead for 
Did you mean: 

Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.

Recovering a pattern based on node comparison

Hello,
I'm relatively new to Neo4J and Cypher and I'm trying to perform a somewhat complex query:

I have a Graph with the following Schema:

(n1)-[r1]-(n2)-[r2]-(n3)

my nodes n1 have a property that is an array of values and an unique ID property

I need to recover this pattern (n1)-[*2]-(n3) where the n1 nodes have different ID properties and that share any element of the array property, example:

assuming (a:n1) (b:n1)
a.ID <> b.ID and any(x in a.values where x in b.values)

Is is possible to recover this patter subset and show it on the browser?

Thanks in advance,

0 REPLIES 0
Nodes 2022
Nodes
NODES 2022, Neo4j Online Education Summit

All the sessions of the conference are now available online