ruby09
May 23, 2022, 6:07am
#1
Hello,
I am not too sure how to get a value from the previous node.
Here is the code that I have tried in the function node below
json: {
name : items.json.name_Of_Requester
}
But doing it this way leads me to the error below.
ERROR: Cannot read properties of undefined (reading ‘name_Of_Requester’) [Line 18]
Jon
May 23, 2022, 9:11am
#2
Hey @ruby09 ,
It is hard to tell looking at your function but my first guess would be you are not looping the items, As a quick test can you try items[0].json.name_Of_Requester
and see if that works?
1 Like
ruby09
May 23, 2022, 9:15am
#3
This worked perfectly. Thank you so much for your help!
1 Like
Hi,
Quick tip for further readers:
To see and understand what is the input of incoming data, use console.log(items);
and open the developer console on the browser. It helps a lot.
3 Likes