I do not understand the idea. Do you want a node that can be manipulated from the code node?
Or simply a node that can store and retrieve data in/from the global variables?
Hi @BramKn,
I would like a node that can be used to define a global variable similar to the Set node, and utilize the Code node to add or remove values from it. ex: an array defined, and then you update/push items to that array after performing certain functions in the code node and at the end of the workflow you retrieve the updated array/variable data.
This functionality used to exist in versions earlier than 0.198, in the function node itself, but after the introduction of the code node, it’s broken.
you may refer to the other topic which I raised where this has already been discussed.
OK so it is 2 things you are talking about.
Like @Jon said we got static data for that. But if it is not working anymore in the code node, this should get fixed. I have faith they will soon.
The second is a node to do the same but more user-friendly.
I want to report what our workflows are doing. I have configured Google Workplace so I can send to a Google Sheets document. The workflow I’m working on is modular. I have a “controlling” flow that runs other flows and processes the return data. I want a report from the flow when it’s done.
Where this comes in, I want to create the document in the control workflow, but I want the called workflows to be able to write to the same document. It may be a different sheet within that document.
To do so, I need to be able to pass the document ID to each flow when it gets called. If the controlling flow could put that document ID in a variable that any called workflow had access, this would be easy.
I developed a community node for n8n, named n8n-nodes-globals, that potentially offers the features you need. This node enables the establishment of constant variables applicable throughout all workflows. Additionally, it permits the alteration of values in various sets without impacting current nodes.