Rule Engine (Multi Column)

Just putting this out there… :sunglasses:
It would be great if this could appear as a core node!

In the meantime here is a component:

Use Case example:
Setting all ZEROES to MISSING:
NOT $CURRENTCOLUMN$ = 0 => $CURRENTCOLUMN$

Limitations

  • Mostly usability; there are also limitations on the UI for a component.

  • It is best to execute the component before configuration so that it can “see” flow variables and column names. This is a limitation of the component architecture.

  • Use keyboard shortcuts to copy and paste flow variable and column references from the lists onto the Rule text area.

  • There may be some instances where the datatype is changed as a result of the application of the rules. I have attempted to coerce datatypes back to the original where possible, but this may not always work.

More details
See component documentation for details. The internals of the component are spaghetti at the moment and I’ve left a couple of additional nodes in there for debug purposes. I may tidy that up at some point… But then again… I may not :wink:

Feedback
Please tag me on the forum with any feedback/ideas/issues.

It would be nice if the list of columns and flow variables could be made smaller but I think there is a bug in the Single Selection Configuration node - it is not respecting the “Limit number of visible options” for a List selection:

image

No matter what I set it to, it just creates a list box with every row displayed.


edit: some thoughts I have in mind for possible future update:

  • The ability to refer to other columns by offset from CURRENTCOLUMN
  • Be able to refer to flow variables using exact same syntax as rule engine
  • Ability to refer to CURRENTCOLUMNTYPE so that rules could differ according to the datatype of the current column