Important Community update: The process for changing your account details was updated on June 25th. Learn how this impacts your Community experience and the actions we suggest you take to secure your account here.

Alteryx Designer Desktop Discussions

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

Extracting Date from Filename

KamenRider
11 - Bolide

Good day,

 

Can I ask for you help in extracting the date from a filename? See below filename.

 

DDB Fest.Daily_01.05.24_Final.xlsx
DDB Sander Daily_01.08.24_Final.xlsx

 

Results of date should be 2024-01-05 and 2024-01-08.

 

Thanks and looking forward for your assistance.

 

Kamen

5 REPLIES 5
Bren_Spill
12 - Quasar

See attached workflow

KamenRider
11 - Bolide

Hi @Bren_Spill 

 

Would you know why I am getting a null result?

 

date.PNG

Hoping for your response. Thanks,

Kamen

nagakavyasri
12 - Quasar

@KamenRider  Try this:

 

Capture13.PNG

binuacs
20 - Arcturus

@KamenRider 

DateTimeParse(REGEX_Replace([File Name], '.*_(\d{2}\.\d{2}\.\d{2})_.*', '$1'),'%m.%d.%y')

image.png

Raj
15 - Aurora

Use this formula 

DateTimeParse((regex_replace([Field1], '.*_(\d{2}\.\d{2}\.\d{2}).*', '$1')), "%m.%d.%y")

delevering the required results

Labels