ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests Early 2026. Make sure to check your account preferences in my.alteryx.com to make sure you have filled out your security questions. Learn more here
Start Free Trial

Weekly Challenges

Solve the challenge, share your solution and summit the ranks of our Community!

Also available in | Français | Português | Español | 日本語
IDEAS WANTED

Want to get involved? We're always looking for ideas and content for Weekly Challenges.

SUBMIT YOUR IDEA

Challenge #58: An Odd String to Date Conversion

Walsh67
Asteroid

My solution...

ebarrus
Meteor

My solution

ivoller
Quasar

I found this pretty straightforward. Went with a formula but I'll come back to see if I can do it with regex

 

Spoiler
new field with date format and formula - iif(left([date],1)="1","20","19")+Substring([date],1,2)+"-"+Substring([date],3,2)+"-"+Substring([date],5,2)
Alconite
Meteor
 
ivoller
Quasar

I managed to come up with a regex solution. Not pretty or practicable but an interesting exercise in conditional replacement.

 

Spoiler
REGEX_Replace([date], "^(1)?(0)?(\d{2})(\d{2})(\d{2})$", "(?{1}20$2$3:19$3)-$4-$5")
berlyma1
Meteor
 
mdgajes1
Meteor

Done. Took me a few minutes to work out a formula. Its different than the solution's. Always interesting to see how many ways there are.

aditi_bala
Atom

Inaugural challenge - I enjoyed it!

jeniferpeden
Meteor
 
JoBen
Bolide

Cheers!