Merge by position mixed data from different customers

Describe the problem/error/question

I have e flow that generates data from multiple customers, creates a message using openAI, merges it with the rest of the data using Merge by Position and sends a slack message with the combination.
Today it messed up, sending the message for the wrong people. That means the merge by position screwed it.

Actually, the execution shows 3 items only in the green lines when there are actually 23. I think this has to do with the problem. Also noted that as the JSON gets big, the interface started to hide it until you click to show it. Might be also related.

What is the error message (if any)?

No

Please share your workflow

Share the output returned by the last node

There’s sensitive data

Information on your n8n setup

  • **n8n version: Version 1.11.2
  • **Database (default: SQLite): ?
  • **n8n EXECUTIONS_PROCESS setting (default: own, main):default
  • **Running n8n via (Docker, npm, n8n cloud, desktop app):cloud
  • **Operating system: MacOS

Hi @Fernando_Taliberti :wave: Thanks for that information!

Could you provide some example data produced by each relevant node, so I can test and see exactly how each of these merge nodes behave? Please don’t share any sensitive information :bowing_man:

Can you also clarify where you’re seeing only 3 instead of 23 items? I’m not too sure exactly where that’s happening based on the description :bowing_man:

Hi @EmeraldHerald. The problem is that the input data that has 23 items is not showing all of them (n8n.io - Workflow Automation).

Look at this print, it says 3 items in the input and 23 in the output, but they shouldn’t increase.

The input actually has 23, but only 3 are showing. Even though, if I collapse one by one in the JSON view I only see 9, it is still more than 3. See picture:

As n8n got lost in the number of items, the merge node in this WF also did, because the merge criteria was position. That’s why our customer’s data got mixed!

Thanks

1 Like

Hey @Fernando_Taliberti,

Has this workflow ever worked? You have 2 inputs going into branch 1 of the merge which is going to make things interesting as that will use different executions which could cause a mix up.

I would maybe try merging those 2 then go into the last merge and see if it makes a difference.

It would be great if you could provide a sample workflow and some mock data that actually shows the issue so we can reproduce it though it doesn’t need to be your live data just something close in structure.

1 Like

Yes, it used to work. But since the incident I changed it to avoid more problems.

I’ll see if I can create mock data. Should I post it here or send to the help e-mail?

Hey @Fernando_Taliberti,

If you can share it here there will be more eyes on it :slight_smile:

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.