Set node data not entering to all rows

I have a workflow ehich picks data from an API and pass them to a quest db table. The API call returns multiple rows of data. I have used 2 seperate set nodes to pass some additional values to the table(this data is not included in API data). One of them, which supplies the date (the function {{$now}} is used in the node) passes the data to all rows whereas the other set node (picks value from prev node) only give value to first row. How can I fix this? Thank you!! I have attached the workflows as well as some images for clarity.



If split in batches only has 1 output you might need to select just the first item. In the new syntax that would be $("<node-name>").first and in older versions something like $items(0).$node["splitinbatches"]

Hi,
Thank you for the respose!!

I am able to get the value to the set node. The issue is while passing the data to quest node. Only the first row is taking the value from set. The rest is showing NULL.

I need the data in all rows.

Regards
Dhanya

Hey @Dhanya_V_Sagar,

I suspect this is down to the way the data is looped, does the input to the node contain the geocode? You could just use $json["geocode"] if it does and that would do the job.

Hi @Jon

Thank you for the response!!
Since there is an Api call in the flow, the required data is not available as input in the set node. I have tried by adding another set node after the split batch node, but again the second node doesnt get the required data. I have to pick from the node list. Any other solution?

Regards
Dhanya

Hey @Dhanya_V_Sagar,

I suspect the issue will be with the extra items in the loop, Have you tried setting the expression to always use the first item?