Problem:
In Col. A I have ContractID, Col B a contract start date and in Col. C I have a contract end date.
I want to output the number of months that occur in the specific years 2017, 2018, 2019, 2020,2021 and 2022 in each contract.
Example input (space delimited):
ContractID StartDate EndDate
AAA 01.04.2019 31.12.2033
BBB 25.09.2020 10.05.2033
CCC 06.06.2017 05.05.2020
DDD 01.04.2019 07.04.2022
Desired output (in Cols)(space delimited):
Yr(2017) Yr(2018) Yr(2019) Yr(2020) Yr(2021) Yr(2022)
0 0 8 12 12 12
0 0 0 3 12 12
6 12 12 5 0 0
0 0 4 12 12 4
Any suggestions?
Bookmarks