We can setup up a trigger to receive email alerts when ungrouped categories are detected in the flow, but how do we modify the flow to group the ungrouped categories? We will cover that in this post using the same flow used in the email trigger post.Current Flow We Setup For Generating TriggerClick on the ‘Group Category’ step and you can see that there are two ungrouped categories as mentioned in the email trigger.There are many ways to include these new categories in to our existing groups, but none of them are perfect.Manual GroupingSince we only have a couple of ungrouped items in the flow, this option will work for us, but it won’t be effective if the number of new items are huge.Algorithmic GroupingWe can try to use one of the built in algorithms like ‘Spelling’ or pronunciation, but it will reset our existing grouping.Warning When Rerunning The AlgorithmIt is ok if our existing grouping is entirely based on a built in algorithm, but what if we fine tuned the results manually? We will have to redo all those optimizations again. It would have been a lot better if Tableau Prep allowed us to keep the existing groups, and run the algorithm to find new matches.Nested Algorithmic GroupingYou can keep the existing groups and run the grouping algorithm again on top of the existing grouping. To do that, add a new group and replace in the existing ‘Group Category’ step. Please note that we are not editing the existing ‘Group and Replace’ step, but adding a new one.Nested Algorithmic GroupingWhile this is the easiest way to integrate new changes when large number of values to be grouped, we are losing flow readability. How will the changes pane look after 10 iterations? How do you know which step replaces whatSo which method should you choose? Well it depends a lot on personal preference, buy here is my take on this.Manual – When I only have a couple of new values to be groupedNested Algorithmic Grouping – When I just want a quick fix.Algorithmic Grouping – When I want to refractor the flow for readability. In that case I will remove all groupings and regroup everything in a single step. SummaryThis was the final post in my Future Proofing Group And Replace Series. SO here is The steps involved:Remove ungrouped(dirty) data from outputGenerate an email trigger when ungrouped(dirty) data is detectedModify the flow to handle the ungrouped(dirty) data Post navigationHow to connect to FTP with Tableau Prep Tableau Prep – Aggregating Strings