Functions such as Year([Date Field]), Month([Date Field]), and Day([Date Field]) would really help with date-based formulas and filter tests.
Until such a time, how about?
DateTimeFormat([Date Field],"%Y") >= '2014'
------
DateTimeFormat([Date Field],"%m") == '10'
-----
Just a thought....
I built some Date functions as a Formula AddIn to do exactly this.
Code is on GitHub: https://github.com/jdunkerley/AlteryxFormulaAddOns
Would be nice to see functions expanded in the next release.
Hi all,
Thanks for the idea (and code!). We're looking at re-vamping all of our DateTime functionality across the product, so we'll keep these ideas in mind when those initiatives kick off.
Best,
Alex
Good news for anyone reading this post, these functions are now available in Alteryx Designer 11.5:
@MarqueeCrew suggested -- DateTimeFormat([Date Field],"%Y") >= '2014'
Thanks for the suggestion. I did use this in a recent workflow. However, for anyone from Alteryx reading this, this is non-intuitive. '2014' implies that 2014 is a string and will be treated like a string, not an integer. I didn't try this when I was working it out on my own for that reason.
Thank you for your idea! This idea was implemented back in 11.5 with the functions:
What function gives the date? for example DateTimeDay(2020-07-05) will give a numeric figure which is 5, what if i want a Sunday?
You can actually use DateTime to achieve this, convert date to string and use custom method
Type Month for just month and day for day. @FreeRangeDingo @gsaval @Philip @KylieF @ARich