# Merge node typeVersion 3 is not working properly

**URL:** <https://community.n8n.io/t/merge-node-typeversion-3-is-not-working-properly/52538>\
**Category:** Questions\
**Tags:** data-transformation\
**Created:** [August 25, 2024, 2:31am UTC](https://community.n8n.io/t/merge-node-typeversion-3-is-not-working-properly/52538 "2024-08-25T02:31:50Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dishui](https://avatars.discourse-cdn.com/v4/letter/d/cc9497/32.png) [@dishui](https://community.n8n.io/u/dishui)\
**Post date:** [August 25, 2024, 2:31am UTC](https://community.n8n.io/t/merge-node-typeversion-3-is-not-working-properly/52538/1 "2024-08-25T02:31:50Z")

</div>

I am at course level 2, doing the [Merging and splitting data | n8n Docs](https://docs.n8n.io/courses/level-two/chapter-3/#merge-exercise)

## Describe the problem/error/question

After adding the merge node to the workflow, it does not produce the desired outcome.  
However, if I copy and paste the workflow from the example on that course page, it works as expected. So I downloaded both workflow JSON and compared the merge node, find that the difference is the version, In the example, the version is 2.1 and the merge node in my n8n is 3. I have n8n version 1.55.3

## What is the error message (if any)?

no error message. just gives no desired output: this is what shown

 ![Screenshot 2024-08-24 at 7.40.54 PM](https://europe1.discourse-cdn.com/n8n/original/3X/8/0/8032c8405b398c7b4825c6689b12b1366346974f.png)  
here is the workflow:

This is the desired out put demonstrated by typeVersion 2.1 of the merge node which if I click on the + sign, I do not get that version

 ![Screenshot 2024-08-24 at 7.39.42 PM](https://europe1.discourse-cdn.com/n8n/original/3X/e/a/ea4ace4672bd781ea468377ac4db9565d703da08.png)  
here is the working example workflow that uses an older merge node typeVersion 2.1:

(Select the nodes on your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)

## Share the output returned by the last node

## Information on your n8n setup

- \*\*n8n version: 1.55.3
- \*\*Database (default: SQLite): postgres
- **n8n EXECUTIONS\_PROCESS setting (default: own, main):**
- **Running n8n via (Docker, npm, n8n cloud, desktop app):** Docker
- **Operating system:** Ubuntu

---

<div class="post-metadata">

**Author:** ![ihortom](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/ihortom/32/11473_2.png) [@ihortom](https://community.n8n.io/u/ihortom)\
**Post date:** [August 25, 2024, 5:23pm UTC](https://community.n8n.io/t/merge-node-typeversion-3-is-not-working-properly/52538/2 "2024-08-25T17:23:17Z")

</div>

@dishui , the problem is not with **Merge** node but rather the returned value in **Code** node. Change it to

```auto
const myObject = [
  {
    name: "Jay Gatsby",
    language: "English",
    country: {
      code: "US",
      name: "United States"
    }
  },
  {
    name: "José Arcadio Buendía",
    language: "Spanish",
    country: {
      code: "CO",
      name: "Columbina"
    } 
  }
];

return myObject;

```

That is, use `return myObject;` in place of `$input.all();`.

When using `$input.all();` you are not returning anything in this case. As a result, there is no data to merge with.

---

<div class="post-metadata">

**Author:** ![dishui](https://avatars.discourse-cdn.com/v4/letter/d/cc9497/32.png) [@dishui](https://community.n8n.io/u/dishui)\
**Post date:** [August 25, 2024, 7:52pm UTC](https://community.n8n.io/t/merge-node-typeversion-3-is-not-working-properly/52538/3 "2024-08-25T19:52:37Z")

</div>

Thanks for a sharp eye

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/system/32/195824_2.png) [@system](https://community.n8n.io/u/system)\
**Post date:** [September 1, 2024, 7:53pm UTC](https://community.n8n.io/t/merge-node-typeversion-3-is-not-working-properly/52538/4 "2024-09-01T19:53:13Z")

</div>

Closed on September 1, 2024, 7:53pm UTC

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