I have the unique project names with me. I am not being able to create a range of past 3 years from today in month/year format. I am looking for a flow which will help me create a range of dates in month/year format.
You can use the Create Date&Time Range node. If you select a 3 years span and enter 36 as the fixed number of the rows you will get the monthly dates. You can manipulate the date values to have exactly what you want. If you want the dates to be dynamic and determined regarding the execution date of the workflow, you can select “use execution date&time” for End date and a variable for the start date.
For the start date variable, you can use another create date&time range node to create 1 row with current execution date value and then use the Date&Time Shift to have the start date.
Thanks a lot @armingrudd. I did get the start and end dates with the 2 nodes. After that, which node will help me in creating the range of month/year between these 2 dates? I see that I cannot send an input to Create Date&Time Range node.
this can also be achieved with less nodes. The Create Date&Time Range node allows to set a negative interval (-1M in this case).
Btw, the Cross Joiner allows you to easily combine the months with your product names.
Thanks a lot for this as well. I was struggling more with the dynamic creation of date range. I wanted both the months and the start date as a flow variable.
If you need to start from the first month, you can shift to -3y, manipulate the month and then pass the date as variable to use it as the start date with 1M interval.