2022: Week 43 - Solution
Solution by Tom Prowse and you can download the workflow here.
The challenge last week is an extension from last week. Once we solved last week, we then realised that it wasn't quite right and there were additional requirements. One of the benefits of using Tableau Prep is that it's easy to iterate on solutions and make changes to previous workflows.
Step 1 - Previous Flow
Step 2 - First Training Session
Using the min date, we can now add in the dates between the min date and first session by using the New Rows step. We want to fill the dates where Min Date <= Date by an increment of 1 day - we call this field Session Date.
Step 3 - Pre First Session Flag
The final task that we need to do is to combine it with the previous rows that we created last week. We can combine them using a union and we want to place this between the Actual Flag and Remove Weekends step. If you have set your flow up differently you need to make sure you are removing weekends after you've combined the tables.
Once we have combined the data we can now output our table that looks like this: