How to use the generate rows tool to add in missing date values?
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hello!
I am trying to see how to use the generate rows tool to add extra rows to my data but not sure on how to do so.
Here is a subset of my data:
Academic Calendar | Session Name | Session | Academic Year | Fiscal Year | Fiscal Year Range | Start Date2 | Start Date | End Date | End Date2 | Model | Weeks Out | Weeks Out Date | Data Through |
Spring Session II – 2025 – March 3, 2025 – April 27, 2025 | Spring Session II | 202525 | 2025 | 2025 | FY24-25 | 3-Mar-25 | 3/3/2025 | 27-Apr-25 | 4/27/2025 | last 3 5's | 0 | 3/3/2025 | 3/2/2025 |
Spring Session II – 2025 – March 3, 2025 – April 27, 2025 | Spring Session II | 202525 | 2025 | 2025 | FY24-25 | 3-Mar-25 | 3/3/2025 | 27-Apr-25 | 4/27/2025 | last 3 5's | 1 | 2/24/2025 | 2/23/2025 |
Spring Session II – 2025 – March 3, 2025 – April 27, 2025 | Spring Session II | 202525 | 2025 | 2025 | FY24-25 | 3-Mar-25 | 3/3/2025 | 27-Apr-25 | 4/27/2025 | last 3 5's | 2 | 2/17/2025 | 2/16/2025 |
As you see above, in the Weeks Out Date column, there are days in between each row that are missing. ie. days between 2/24/2025 and 3/3/2025.
This is an example of what I mean where the data between each of the weeks out date is filled in.
Academic Calendar | Session Name | Session | Academic Year | Fiscal Year | Fiscal Year Range | Start Date2 | Start Date | End Date | End Date2 | Model | Weeks Out | Weeks Out Date | Data Through |
Spring Session II – 2025 – March 3, 2025 – April 27, 2025 | Spring Session II | 202525 | 2025 | 2025 | FY24-25 | 3-Mar-25 | 3/3/2025 | 27-Apr-25 | 4/27/2025 | last 3 5's | 1 | 2/24/2025 | 3/2/2025 |
Spring Session II – 2025 – March 3, 2025 – April 27, 2025 | Spring Session II | 202525 | 2025 | 2025 | FY24-25 | 3-Mar-25 | 3/3/2025 | 27-Apr-25 | 4/27/2025 | last 3 5's | 1 | 2/25/2025 | 3/2/2025 |
Spring Session II – 2025 – March 3, 2025 – April 27, 2025 | Spring Session II | 202525 | 2025 | 2025 | FY24-25 | 3-Mar-25 | 3/3/2025 | 27-Apr-25 | 4/27/2025 | last 3 5's | 1 | 2/26/2025 | 3/2/2025 |
and so on.
- Labels:
- Data Investigation
- Transformation
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@bryanmac_92 Here is how to use the Generate Rows tool for padding the missing days.
The Generate Rows tool cannot refer to previous/next record unlike the Multi Row Formula tool. In order to properly set the Condition Expression, it's essential to put another column. In my WF, I created a column 'limit' for that purpose.
As a general caution, if Condition Expression already returns 'False' at first loop, those rows will be gone from output of the Generate Rows tool. To keep the original record for sure, Condition Expression shall be properly set so that Condition Expression returns 'True' at first loop.
The Generate Row tool is tricky but very powerful and unique tool that cannot be directly replaced by any other tools.
