Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Convert Date

nmotiani
5 - Atom

How can I convert the field for date from MM-DD-YY to MMMYY

 

For example Date = 12/1/23

Desired Output = Dec23

 

and then I would like to combine different fields to create a unique identifier such as 

 

Fruit = Apple

Account Number = 1234

Date = Dec23

 

Desired Output = Apple_1234_Dec23

Would appreciate your help thank you

5 REPLIES 5
alexnajm
16 - Nebula
16 - Nebula

DateTimeFormat(DatetimeParse([Date], "%m/%d/%y"), "%b%y")

 

Then you can add them together as you need: [Fruit]+"_"+[Account Number]+"_"+[Date]

binuacs
20 - Arcturus

@nmotiani one way of doing this

image.png

nmotiani
5 - Atom

Im not sure why my formula is breaking and it only shows the first two components but not the date

 

my mistake the date originally shows like 12-01-23 is that whats causing the issue

alexnajm
16 - Nebula
16 - Nebula

first, your Date field needs a bracket at the beginning and end - like this: [Date]

 

second, yes that does change things - it would be "%m-%d-%y" if it's month first.

nmotiani
5 - Atom

This worked thank you so much appreciate it

Labels