Referencing the previous/incoming node

I am still puzzled about the node references when writing my expressions.

What works fine is {{$node["foo"].data["query"]["txt"]}}. No surprises there.

Screen Shot 2021-01-23 at 18.40.59

But I of course I don’t want to reference the node by a fix name “foo”.
I want to keep things more flexible and use node that actually passed the data.

But the “current node” does not have that data - and there is no “previous node”.

What am I missing?

If the node is connected and has output data you should see the data of the incoming node under “Current Node -> Input Data” in the Expression Editor.

You can also access the incoming data directly via $json. So in your case $json.query.txt.

1 Like