community
cancel
Showing results for 
Search instead for 
Did you mean: 
Do you have the skills to make it to the top? Subscribe to our weekly challenges. Try your best to solve the problem, share your solution, and see how others tackled the same problem. We share our answer too.
Weekly Challenge
Do you have the skills to make it to the top? Subscribe to our weekly challenges. Try your best to solve the problem, share your solution, and see how others tackled the same problem. We share our answer too.
Unable to display your progress at this time. Please try again a little later, or contact an administrator if you continue to see this error.
Getting started with Designer? | Start your journey with our new Learning Path!

Challenge #46: Formatting a Date from an Integer

Meteoroid

My solution for this challenge.

Alteryx Partner

My solution

 

Spoiler
FORMULA:
DateTimeParse(
IF Left([date], 1) = '1'
THEN '20' ELSE '19' ENDIF
+ Right([date], 6),
'%Y%m%d')

challenge_46_RODO_Solution.png
Asteroid

Done!

Asteroid

My solution

Atom

 

I chose to sort out the year, then deal with the format in one go.  I like the single formula route - very slick!

Asteroid
 

Solved

Asteroid
Spoiler
sarahjohnson_0-1572290700065.png
Meteor

Here's my attempt

Meteor

This is my solution:

 

Evalute 1st digit and concatenate 19 or 20 (according to rule) to the rest of string. Then, parse to date.