Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
03-16-2021 08:01 AM
Hi,
I would like to be able to return multiple nodes by searching for a list of node properties (and e.g names) in one search statement. Is this issue solvable by using the Search phrase functionality, or any other known workarounds?
Solved! Go to Solution.
03-18-2021 09:08 AM
This was solved in the Customer support hours with the use of the split() of the input.
Examplewise with the search phrase that returns a comma separated list of customers with their relationships:
WITH $customerNumberListString AS content
WITH [i IN SPLIT(content, ",") | TOINTEGER(trim(i))] AS values
MATCH (n:Entity)
WHERE n.CustomerNumber IN values
with collect(id(n)) as nodes
CALL apoc.algo.cover(nodes)
YIELD rel
RETURN startNode(rel), rel, endNode(rel);
03-18-2021 09:08 AM
This was solved in the Customer support hours with the use of the split() of the input.
Examplewise with the search phrase that returns a comma separated list of customers with their relationships:
WITH $customerNumberListString AS content
WITH [i IN SPLIT(content, ",") | TOINTEGER(trim(i))] AS values
MATCH (n:Entity)
WHERE n.CustomerNumber IN values
with collect(id(n)) as nodes
CALL apoc.algo.cover(nodes)
YIELD rel
RETURN startNode(rel), rel, endNode(rel);
All the sessions of the conference are now available online