[Enhancement] Expression Node - add ability to access a previous row's output value for the current column being appended/replaced

Description:
Currently from what I have seen, the Expressions node can only reference the INPUT table value of a column that it is replacing the value of, although it can reference the output value from previous expressions, for other columns being created on the current row.

I’d like to see it enhanced so that it may also be able to reference a previous OUTPUT value for the same column that the expression is appending/replacing.

e.g. If I have a column $COST, I’d like to be able to create a $RUNNING_TOTAL column containing the cumulative sum of the current row’s $COST plus previous row’s $RUNNING_TOTAL, such that my expression would be the equivalent of :
$COST + OutputTable($["RUNNING_TOTAL",-1])

I did spot that in the new Expressions Row Filter, there is a panel on the left “Output Table” but I cannot determine its purpose:

I am hopeful that this is perhaps a clue that access to “Output Table” might be forthcoming in a future Expressions node? Such a modification would make cumulative calculations straightforward, and is a feature that is much sought after, espcially by those who have “seen the light” in moving to KNIME from Alter…native products..

4 Likes

Edit- I misread this on an initial quick read thinking it was about the Input / Output table of the Evaluation area, so removed the post.

1 Like

Hi @takbb,

We have not intended to support this with the Expression nodes. However, your use case sounds reasonable. I will bring this to the team to check if and how we could support this.

I did spot that in the new Expressions Row Filter, there is a panel on the left “Output Table” but I cannot determine its purpose

Good catch. This is a leftover. In the Python node, it displays the currently configured outputs and the code to assign them. However, in the Expression Row Filter, it has no purpose, and we will remove it.

1 Like

Thank you for the suggestion @takbb.

I am attaching the ticket created for this request (AP-23640).

Best,
Keerthan

1 Like

Internal ticket ID: AP-23640
Summary: Expression Row Filter shows empty “Output Table” element in input/outputs pane
Fix version(s): 5.4.0