This is different than other 'need date difference posts' I've found bc I need to parse out the difference between dates by the minute. I tried solutions in this post and others with no luck.
I have this 'UnavailableTime' table
| UnavailableID | UnavailableFrom | UnavailableTo |
|---|---|---|
| 1 | 2/1/2023 8:00:00 AM | 2/1/2023 8:03:00 AM |
| 2 | 2/2/2023 10:30:00 AM | 2/2/2023 10:32:00 AM |
I need a minute breakdown for each timeframe the person was unavailable. Like this:
| UnavailableID | MinuteBreakdown |
|---|---|
| 1 | 2/1/2023 8:00:00 AM |
| 1 | 2/1/2023 8:01:00 AM |
| 1 | 2/1/2023 8:02:00 AM |
| 1 | 2/1/2023 8:03:00 AM |
| 2 | 2/2/2023 10:30:00 AM |
| 2 | 2/2/2023 10:31:00 AM |
| 2 | 2/2/2023 10:32:00 AM |
Could someone please help me!
I've tried joining my 'UnavailableTime' table to a calender table that has every minute for the month, then doing a count of minutes inbetween the From & To times with no luck.