Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.

Multi-Record DB Inserts/Updates

Avatar

Former Community Member
I have a situation where I will receive a form that contains a repeating node of data for which I will need to do a database update or insert for each repeated node.



Is there an efficient mechanism to iterate over these nodes and call the Execute SQL Statement as many times as there happen to be nodes? I have seen examples of looping constructs where you must set counters as process variables and then have a setValue process update that each time and combine it with a decision point to check if the counter matches the nodecount.



I am hopeful there might be a more efficient way to do this that I am overlooking.



Thanks in advance!
1 Reply

Avatar

Level 10
That's the only way other than using the Script service or writing your own custom component and write code to do the looping.



Jasmin