I need to save to a table the fields "startDate", "endDate", and "dateAlias" from a given date range. Saving should be by 30 days. So, let's say the date ranges from January 20, 2020 to march 20, 2021. I need to save to my table a period before the start date starts to the date end like this:
startDate | endDate | dateAlias |
2000/01/01 | 2020/01/19 | Month00 |
2020/01/20 | 2020/02/19 | Month01 |
2020/02/20 | 2020/03/19 | Month02 |
2020/03/20 | 2020/04/19 | Month03 |
and so on.
the start date of the first row is static. I hope someone can help me. Thanks in advance.