I am trying to find all Relationship of a node - using a Query Like this in neo4j
MATCH (a:User)-[r]-(b) RETURN a, collect(r), collect(b) limit 10
But I am getting this Error ,could you please help me?:
2021-11-18T11:37:20.0844+0100 [Neo4jDriverIO-2-2] WARN
org.springframework.data.neo4j.core.Neo4jPersistenceExceptionTranslator
- Don't know how to translate exception of type class org.springframework.data.neo4j.core.mapping.NoRootNodeMappingException
2021-11-18T11:38:41.0486+0100 [Neo4jDriverIO-2-2] ERROR
handler.CommonHandler - SOME ERROR
OCCURRED: Could not find mappable nodes or relationships inside
Record<{r: relationship<1234>, collect(r):
[relationship<12345>], collect(b): [node<6565>]}> for
org.springframework.data.neo4j.core.mapping.DefaultNeo4jPersistentEntity@34cb0e49
I know that
starting with Spring Data Neo4j 6, relationship cannot be top-level entities anymore.
As a consequence, my repository methods return
Mono< User > findARelationship();
thank you as always for your time.