Knime output filename concatenated with Current MOnth/Year

Hi All,
I am trying to concatenate previous month/year in ‘MMM’YY’ format with exported excel filename , which extracted file from knime workflow . So something like -
"Population - Feb’23.xlsx "
Kindly let me know which node can used to get this done.

Thanks
RS

Hi @rds,
You can use a Create Date&Time Range node and set the number of rows to 1 and the start date&time to “current execution time”. Then you can use the Date&Time Shift node to subtract one month, followed by a Extract Date&Time Fields to get the year and the month. Now you can concatenate those using a String Manipulation node and create a file name using the Create File/Folder Variables node. This variable you create can then be used in the Excel Writer.
Kind regards,
Alexander

2 Likes

@rds you can take a look at these examples:

3 Likes

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.