This seems like it should be easy to do, but I can't figure it out. I'm trying to identify runs by looking at a field called 'STEP'.
I used a Multi-Row tool for 'STEP-1' which looks at the previous step value. When 'STEP-1' = 0 and 'STEP' > 0, it's a new run and I want a new column to start with '1' as the run. The next time the test passes (goes from 0 to a non-zero number), I want run '2' listed, which would be the current value + 1.
When I try and reference the Output Column (Step_Test) in the formula tool, it gives me an Unknown Variable error.
Solved! Go to Solution.
Can you post the config screen of your multi-row formula? If you properly create [step_test] there you shouldn't have that problem here...
I know I've done this before and it always works, not sure why I'm getting the error here. The multi-row tool is set to an Int32, and all of the step values are integers.
@mattcoleman
The unknow variable should the column "Step_Test", and you should initial it first.
It seems that you are creating the new coloumn "Step_Test" with the Formula tool but you also using it in the formula.
Add one expresson above this one as below
hi @mattcoleman
It seems to me like using the "Group by" within the Multi-row formula can solve your problem.
However i am not 100% able to follow the description of the logic flow. can you share a mock data to show input and expected output?
Dawn.
This is a simple example of what I want. Imagine I have the 'Time' and 'Step' columns, and I want to create the 'Run' column that identifies a new run after the step resets from 0 to a non-zero number.
Hi @mattcoleman
Can you provide this data in an excel file. You can solve this using Multi-row formula tool.
Thanks @atcodedog05 . I think this method is close, but as you can see above the Run (Expected) does not match the new Run generated column. After Run 2, there are multiple zero steps, which shouldn't increment to step 3 until you see another non-zero value. Your output makes that Run 3 and then Run 3 becomes Run 4.