How to get binary data from previous node and solve merge conflicts

I have a similar scenario to the following one running on a biggest workflow:

The problem here is that “Extract from PDF” has no contect (False branch), “Merge” node is working well (both inputs are green), “Edit Field” takes the data correctly and “AI Agent” works correctly sendit info back to the chat (as it is the last node executed).

But when “Extract from PDF” has content (True branch), “Edit Field” works well and “AI Agent” works well too but doesn’t send the info back to the chat because the “Input 2” of the “Merge” node is executed (green) but “input 1” is not executed. So it stays waiting for it to complet and the chat says something like “[No response. Make sure the last executed node outputs the content to display here]”

How can I solve this situation? Is the merge node correctly configured? I really only need the binary data from chat when “Has content” is false.

Information on your n8n setup

  • n8n version: 1.76.1
  • Database (default: SQLite): PostgreSQL
  • n8n EXECUTIONS_PROCESS setting (default: own, main): Don’t know
  • Running n8n via (Docker, npm, n8n cloud, desktop app): cloud
  • Operating system: Windows

Any help on this? @jan

Welcome to the community @ServiciosIT !

Tip for sharing information

Pasting your n8n workflow


Ensure to copy your n8n workflow and paste it in the code block, that is in between the pairs of triple backticks, which also could be achieved by clicking </> (preformatted text) in the editor and pasting in your workflow.

```
<your workflow>
```

That implies to any JSON output you would like to share with us.

Make sure that you have removed any sensitive information from your workflow and include dummy or pinned data with it!


To be able to pass binaries your Set node has to be instructed to do so. You either be specific about the binary field to also be included in addditions to JSON data or include all the fields.

Also note that data is not a JSON field but binary. Though even if you use $binary.data you will get the metadata about the binary, not the binary itself. To get the actual banary through do as shown in one of the two below screenshots.

Hi @ihortom and thanks for the reply.

Even if check that option the Set module still not having the binary data, im sharing the updated workflow:

In other hand, I still have this problem:

The PDF that I upload have text so it goes through the TRUE branch, but merge still waiting for FALSE to resolve…

As per design of your workflow :slight_smile: . You seem to expect both “true” and “false” to pass the data at the same time. It’s either true or false. Why would you expect the bolean condition to be true and false at the same time?

In your design, for the Merge node to pass the data, there has to be data on both its inputs.

But if I link the false branch directly to the HTTP Request I can’t get the binary data from the chat, because I can only use on the Extract From File node, it doesn’t do the passthrough.

I think I understood your problem now. Indeed using Merge here interferes with returning the data back to the chat. You need to get rid of Merge node completly. To allow the binary through, you need to enable it in Extract from File node.

2 Likes

That’s it!

Now I don’t need the Merge node to get the binary and I pass it through the Extract + If node correctly.

Thanks a lot!

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