Using LEFT formula for extracting a month from a full date, 0 in month missing
Hello,
I am using a Left and Right column formula to extract the Month and Year from a full date column. The formula is successful, however, it is returning only the month number that is not 0.
01/12/2022=LEFT(MONTH [Date], 2) + "/" + RIGHT(YEAR [Date], 2) = 1/22
I need it to return 01/22 to ensure I can properly sort the data in the reports.
Thank you in advance for any assistance you can provide!
-Hannah
Best Answer
-
Try this:
=IF(MONTH(Date@row)< 10, "0", "") + MONTH(Date@row) + "/" + RIGHT(YEAR [Date], 2)
Answers
-
Try this:
=IF(MONTH(Date@row)< 10, "0", "") + MONTH(Date@row) + "/" + RIGHT(YEAR [Date], 2)
-
Yay! Thank you @Paul Newcome! That worked beautifully, thank you!
Help Article Resources
Categories
Want to practice working with formulas directly in Smartsheet?
Check out the Formula Handbook template!
Check out the Formula Handbook template!