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.

how to use apoc.periodic.iterate inside foreach in neo4j

how to use apoc.periodic.iterate inside foreach in neo4j

2 REPLIES 2

I tried and it is not allowed.  that was my initial thought, as the 'foreach' is limited to in what cypher statements it supports. 

What are you trying to do?  I am sure you can write the query without a 'foreach' statement.  Can you provide the query?

sorry for delay

 
:param node_id : 'id'
with $node_id as par
match (u:User) where u[par] is not null with u,par
with apoc.map.fromLists(
[par],
[u[par]]
) AS output
CALL apoc.merge.node(
["child"],
output
) yield node return node
 
I want to make the above script run for multiple times for other parameters using loop could you please suggest on this.