Hello all,
In column [Layoff Periods], I have a list of beginning and end dates separated by " | ". Example, 10/20/2010-11/20/2011 | 12/15/2018-10/10/2019 | 12/12/2022-12/13/2022…
In the same row, I have column [Start Date] with a single date. Example, 10/01/2015. If any of the beginning dates in [Layoff Periods] (in this case 12/15/2018, 12/12/2022) occur after [Start Date] of 10/01/2021, I would like to return only those list values so I can then calculate the durations and add those together for a total number of hours.
The list returned in this case would be 12/15/2018-10/10/2019 , 12/12/2022-12/13/2022
The following was my stab at a solution but of course SELECT doesn’t work for a non-referenced list-- correct? Any other ways return values from a list dependent on a condition? Or any other way to go about this?
SUM(
EXTRACTDURATIONS(
SELECT(SPLIT([Layoff Periods], " | "), [Replaced Start Date]<=DATE(CONCATENATE(EXTRACTDATES([Layoff Periods])))
)
)
)
Thanks!