[Loop over items] How to collect data in "loop" branches into the "done" branch?

Describe the problem/error/question

I use a Loop over items node, and I want to collect results from all the iterations into the “done” branch (by the Edit Field node). But I can get information from only 1 loop branch (the 1st iteration). With other brands, the return result in “done” branch is “undefined”.

Please share your workflow

I want to collect values from the Edit Field 1, Edit Field 2, Edit Field 4 (interations in loop branches) into the Edit Field 3 (done branch).

But in Edit Field 3, I get 2 undefined values as below:

Thank you for all your help!

Information on your n8n setup

  • n8n version: 1.98.2
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): local with npm
  • Operating system: Windows10 pro

Hey @Hong_Dao hope all is well.

Try this approach:

General idea:
name output the same, then aggregate in the done branch.

It worked… Thank you so much!