# adding dates based on quarter

✭✭

Hiya,

I am trying to create a formula to add specific dates based on the selected Quarter.

e.g., I select 'Y3Q1' in the Quarter column and it outputs '9/1/2023' in the Date column.

I thought I could do this with IF statements but its a no-go:

IF([Column13]@row= "Y1Q1 " , " 9/1/21 " , IF ( [Column13]@row= " Y1Q2 " , " 12/1/21 " , IF ( [Column13]@row= " Y1Q3 " , " 3/1/22 " , IF ( [Column13]@row= " Y1Q4 " , " 6/1/22 " , IF ( [Column13]@row= " Y2Q1 " , " 9/1/22 " , IF ( [Column13]@row= " Y2Q2 " , " 12/1/22 " , IF ( [Column13]@row= " Y2Q3 " , " 3/1/23 " , IF ( [Column13]@row= " Y2Q4 " , " 6/1/23 " , IF ( [Column13]@row= " Y3Q1 " , " 9/1/23 " , IF ( [Column13]@row= " Y3Q2 " , " 12/1/23 " , IF ( [Column13]@row= " Y3Q3 " , " 3/1/24 " , IF ( [Column13]@row= " Y4Q4 " , " 6/1/24 " , IF ( [Column13]@row= " Y4Q1 " , " 9/1/24 " , IF ( [Column13]@row= " Y4Q2 " , " 12/1/24 " , IF ( [Column13]@row= " Y4Q3 " , " 3/1/25 " , IF ( [Column13]@row= " Y4Q4 " , " 6/1/25 " , IF ( [Column13]@row= " Y5Q1 " , " 9/1/25 " , IF ( [Column13]@row= " Y5Q2 " , " 12/1/25 " , IF ( [Column13]@row= " Y5Q3 " , " 3/1/26 " , IF ( [Column13]@row= " Y5Q4 " , " 6/1/26 " ,

Any insight would be appreciated!

• ✭✭✭✭✭✭

You have a lot of spaces that need to be cleaned up.

You are also going to want to use the DATE function to output dates.

DATE(yyyy, mm, dd)

IF([Column13]@row = "Y1Q1" , DATE(2021, 09, 01), IF([Column13]@row = "Y1Q2" , DATE(2021, 12, 01), IF([Column13]@row.................................................

• ✭✭✭✭✭✭

You have a lot of spaces that need to be cleaned up.

You are also going to want to use the DATE function to output dates.

DATE(yyyy, mm, dd)

IF([Column13]@row = "Y1Q1" , DATE(2021, 09, 01), IF([Column13]@row = "Y1Q2" , DATE(2021, 12, 01), IF([Column13]@row.................................................

• ✭✭

Thank you so much!

• ✭✭✭✭✭✭

Happy to help. 👍️

## Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!