COMPARISON IN DATA SET

What node can i use to achieve the below?

image

On the expected output, it would mark as “TRUE” if all are under SOLD and will be “FALSE” it there is other description

Here’s a prototype…

First group by and get the description as a set.
Then use Column Expressions Array Functions to check if the set for each Ref ID contains “SOLD” AND has only one element.

datasetcomparison.knwf (77.1 KB)

image

5 Likes

Hi @lovebau , you could try doing a GroupBy node, Group by reference Id and create a unique concatenation of Description. Follow this with a Rule Engine setting to TRUE where the concatenation has returned “SOLD” and “FALSE” otherwise.

4 Likes

@MartinDDDD … sometimes the forum is like playing a variation of “snap!” :rofl:

1 Like

:smiley: you must have posted pretty much exactly at the same time lol

1 Like

@MartinDDDD @takbb thank you so much for your inputs! :slight_smile: what if I have more than two descriptions? other than SOLD and STALE I have a couple more description would this still work?

1 Like

As long as you only want to show true for ids that are all on sold it should work for as many categories as you like w/o need for change.

2 Likes

Hi @lovebau , as @MartinDDDD has said, the various descriptions don’t matter as long as the rule remains the same. Currently it is a binary true/false for “all sold” vs something else. If additional descriptions brings additional rules then a different solution may be required.

1 Like

@MartinDDDD @takbb thank you so much for all your inputs! Everything was very helpful :slight_smile:

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