Let’s say we were given Table Name, Set and we want to calculate: Cumulative Set, Change,Added and Joining. How would you go about that?
Cumulative Set adds anything to the SET that doesn’t exist.
Change is to measure if anything was added or not.
Added tells us what is added.
Joining tells us what is all the keys that exist in current set and previous cumulative set. (If Change is false this is null)
Why I ask I am not sure how programmatic global variables work in Knime.
I think you could use recursion to do that:
However the “global variables” which you want to have for this… do not exists (would make some things easier)
You could use the JavaSnippet Node instead (as you can keep a variable through each row step here)
I think Java Snippet is the easiest solution here, however I think the recursion is also doable if you want to do it without coding
I used the Moving Aggregation node that way you don’t have to loop or worry about global variables.
Thanks for your solution
Didn’t know about the moving aggregation node - great to know
HI there @shubhamss,
nice one! I’m interested so if you don’t mind could you share workflow example for data given in first post?
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.