Hi All,
I am trying to add a formula that converts all my dates to its specific month. for Example 06/19/2020 must just say JUNE.
The below formula did not work.
DateTimeFormat([Field1],"%m")
Can someone help me with the phrase,
Solved! Go to Solution.
Hi @RAJAYKUMAR001 you would need to convert your dates into a format that alteryx recognises as a date which is a YYYY-MM-DD format then you could use datetiemformat formula to make it a month. I have mocked up an example.
Hi @RAJAYKUMAR001,
Try using the below phrase:
DateTimeFormat([DateTime_Out],"%B").
Further more I would like to add if you have multiple formats coming in the input, you first need to convert them into a date format that Alteryx Recognizes(YYYY-MM-DD)
I hope it solves your issue.
Did not work,
I get this warning in orange
Formula (20) DATETIMEPARSE: Cannot convert "2020-04-29" to a date/time with format "%m,/%d/%y": Month number is out of range 1..12: '2020-04-29'
Should I have to use select and change the string type?
Hi @RAJAYKUMAR001 you just need to match the syntax to your date format "%y-%m-%d" would work. I amended my workflow to showcase this. If this does not work can you share an example of your data so it easier to mock up workflow?
Thank you,
It worked.
I did try that as well.
With your sample I realized that the data string type in Formula bar must be V_Wstring. I had kept it as Date. That was another reason.