Hello,
I need help building out the logic that will insert a row based on a few conditions.
When the hours type = HSB and the max date for "HSB" hours type is older than "forecast" hours type max date then insert a row with the hours set to 40
Date | Employee ID | Hours_Type | Hours | Min Date | Max Date |
2020-01-19 | 01 | Actual | 38 | 2020-01-19 | 2020-02-09 |
2020-01-19 | 01 | Forecast | 19 | 2020-01-19 | 2020-04-05 |
2020-01-19 | 01 | HSB | 40 | 2020-01-19 | 2020-02-09 |
Please let me know if you can help.
Thank you,
Rahshid
Solved! Go to Solution.
@aria_rahshid1 Hi Rahshid, check out the attached solution, hopefully you can use similar logic to identify the new rows to be generated, then use a union tool to add the data points back to the main data table:
Hi Aaron,
Thanks for the help. Your workflow helped , but was quite what I was looking for. Essentially I want to generate one l additional row for HSB until i reach the max forecasted date. So if an employee shows forecasted hours all the way through april 5th I want an HSB record inserted until april 5th . What would you adjust in your workflow to accomplish this or do you have another idea to solve this problem ?
Kind Regards,
Rahshid