List of All Variable Created in A Workflow

Hello all dear Knimers,
I got a Workflow from my colleague and I am reviewing it! is there any way to find out in which node an variable is created?! I mean I keep seeing an variable in upstream but I cannot find out in which node this specific variable has been created! is there any way to find out?
many thanks in advance

Hi @psfard

This might not be the best method, but you could try going into the KNIME workspace, then into the folder of your workflow, and using the Windows search tool (in my case) to search for the name of the variable, if you know it.

With a bit of luck, it will locate the parameter file that uses this variable, and from there, you can trace back to the name of the node that uses it. This should give you an idea of which node is involved with the variable, as well as its ID.

Next, you’ll need to search your workflow for nodes that use this specific node to find the variable in question. You’ll even find the ID in the OwnerID column, as long as there aren’t too many nodes of the same type.

I’ve tried to include a few screenshots.

However, it’s true that having an integrated search tool in KNIME to find variables, nodes, etc., would be very helpful, or maybe I’m not aware of one.

1 Like

@psfard I once built this meta search workflow to see if a specific term would occur in a node

Then there is this component but I am not sure if it will provide flow variables

3 Likes

@Stephane73 many thanks for your solution, although it is very creative but as you already have mentioned, it needs more than a bit luck to get lucky with windows crappy search :smile:

@mlauber71 thanks for sharing your workflow with us , however I investigated it and couldn’t find any specific place which lead me to list of variables :thinking:

Hi @psfard, this is one of the areas where the Classic UI continues to have functionality that has yet to appear in Modern UI,

In Classic UI, finding the node that created a variable is relatively straightforward and I have used this to good effect on a large number of occasions.

Take the following (contrived for the purpose) workflow:

Opening the Flow Variable table from the Column Filter I see that I have two flow variables “Greeting” and “VarX”. As has been mentioned already, we can see the Owner ID of these 3:26 and 3:25.

In Classic UI, choose the “Find Node” menu (e.g. mapped here to Ctrl F)

image

The Find node dialog opens

Simply type in the required owner id for the variable in question:


and then select the node that is suggested to find it on on the workflow

image

I am very much hoping that this same functionality will appear soon in Modern UI.

In terms of getting a list programmatically, I haven’t got a solution to this as yet. Although the KNIME views of variables (both in Classic and Modern) shows the owner id of a variable on the screen, I have not found a way of actually accessing this. It would be nice if there were a node for extracting this.

If that were available, the other part of the jigsaw could be to use the Timer Info node, as this can give the node types and their IDs, so you’d then be able to match it up easily.

At the moment though, visually mapping individual flow variables to nodes is all I can find through the UI.

I’ve added the following post in feedback and ideas.

3 Likes

Hi @takbb thanks a lot for this comprehensive answer as a matter of fact it works and I really appreciate your help

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.