I want to group data based on specific fields and then filter records based on that grouped data.
Here is my sample data
| Cookies | Fruits | Vegetables | Cakes |
| Chocolate Chip | Apple | Onion | Chocolate unsweetened |
| Chocolate Chip | Apple | Onion | Vanilla |
| Snickerdoodle | Strawberry | Kale | Tiramisu |
| Peanut Butter | Blueberry | Spinach | Tres Leches |
| Chocolate Chip | Apple | Onion | Chantilly |
I want to look for for records that are duplicates (match) for the Cookies, Fruits, and Vegetables fields. For the records that are duplicates on those fields, I want to filter based on the Cakes field.
For rows 1, 2, and 5 that match on the Cookies, Fruits, and Vegetables fields, I want only one of the records to continue through the workflow. I want to prioritize the record that contains the string 'unsweetened' in the Cake field.
If the record has no duplicates based on the specified fields (Cookies, Fruits, Vegetables), I want it to pass through as normal.
In the example above, I would want the following fields to continue to the next step of the workflow:
| Cookies | Fruits | Vegetables | Cakes |
| Chocolate Chip | Apple | Onion | Chocolate unsweetened |
| Snickerdoodle | Strawberry | Kale | Tiramisu |
| Peanut Butter | Blueberry | Spinach | Tres Leches |
Please let me know if this does not make sense.