I need to create some output files based on running months (i.e Jan to Dec). However, e.g. i have Jun actual data only in Jul, so today_date function do not fit in when i renaming my file through formula tool. Any good suggestions? I would want my output file name will dynamically changed based on actual data month instead of today, but i do not have the data month field available in the data set.
Hi @kennynsw
If you know that you will always have the previous month's data in the current month. You can calculate the previous month from the current month like below.
Workflow:
I hope this gives you an idea.
Hope this helps 🙂
May i ask what option i should choose in output tool?
I ticked take field from field name and change entire output path by choosing my output path file column created.
However, “writing to database” that field cannot dynamically take my output file path. I need to manually type my file name, does it mean that i need to change the path every month?
Hi @kennynsw
File Name column formula would be something like below.
// FullPath & FileName
"Output"
// Month
+ DateTimeFormat(
DateTimeAdd(DateTimeFirstOfMonth(),-1,"month")
,"%B %Y")+".xlsx"
//SheetName
+"|||Sheet1"
In Output tool you just need to set a temp file. This will be taken reference for file options. Set it change path of the file name and it will output the mentioned filename.
Hope this helps 🙂