Describe the problem/error/question
Have merged two data sets together using Merge (Combine/Multiplex)
Input 1 is a item list split that has variables lengths depending on the last time it was run
Input 2 is a basic array with 2 items like this.
What is the error message (if any)?
In the merge node, using the basic options i can successfully and the columns for WorkOrderID and WorkOrderNumber however i was hoping to use the expression mode option on the multiplex line to not only combine the two inputs but instead of repeating the WorkOrderID and WorkOrderNumber, increase it by 1 per additional row.
Is this possible?
Please share your workflow
## Information on your n8n setup
Latest on prem version on Docker using debian
Thanks in advance.
Can you share the output of the item lists node and also some example json of what you are expecting it to look like and we can see what we can do.
Thanks for the reply.
Just started testing this and need all the help i can get.
the current output of the list node (Sample Below )
The output of the GetLastMexWO is below
The output of my merge is
What i wanted.
I wanted to add the 2 columns incrementedWorkOrderID and incrementedWorkOrderNumber to the end of each row as shown above. So the merge multiplex kind of did the trick.
But I was trying to find a way that instead of the incrementedWorkOrderID and incrementedWorkOrderNumber being duplicated for each row, that it would take the input numbers being the first number shown on the top row (21264 and 22065) and increase it by 1 for each additional row as required.
I was then going to try split out the rows again and post them to the api to receive the final reply with the additional processed fields before reposting the final values. I believe to do this i need to use loop but i will tackle that when i get to that point.
So for that maybe an Edit Fields node after the merge would do the job then you can increase the number by the
$itemIndex so something like the example below, In this the second Edit Fields node will increase the ID by the index of the item so if you had 5 items leaving the first item would increase by 0, then 1, 2, 3 and so on giving you an output like this…
Worked Like a Charm!!!
Thanks so much!
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.