Nested IF Formula
I would like the IF statement to return a specified value if based upon date ranges. For example, if a date falls within a range:
09/01/23 - 11/30/23 should return the value "Q1"
12/01/23 - 02/29/24 should return the value "Q2"
03/01/24 - 05/31/24 should return the value "Q3"
06/01/24 - 08/31/24 should return the value "Q4"
This is what I have so far: =IF([End Date]@row >= DATE(2023, 9, 1), "Q1")
Any assistance you can provide would be greatly appreciated!
Best Answers
-
See if this works for you. This ignores the days and year and simply matches the quarter based on the month.
=IFERROR(IF(AND(MONTH([End Date]@row) >= 9, MONTH([End Date]@row) <= 11), "Q1", IF(OR(MONTH([End Date]@row) = 12, MONTH([End Date]@row) <= 2), "Q2", IF(AND(MONTH([End Date]@row) >= 3, MONTH([End Date]@row) <= 5), "Q3", "Q4"))), "")
-
Awesome, I'm glad you were able to learn something from it!
👍
Answers
-
See if this works for you. This ignores the days and year and simply matches the quarter based on the month.
=IFERROR(IF(AND(MONTH([End Date]@row) >= 9, MONTH([End Date]@row) <= 11), "Q1", IF(OR(MONTH([End Date]@row) = 12, MONTH([End Date]@row) <= 2), "Q2", IF(AND(MONTH([End Date]@row) >= 3, MONTH([End Date]@row) <= 5), "Q3", "Q4"))), "")
-
@Carson Penticuff Thank you so much! That works perfectly!! I appreciate you so much. I learned something new.😊
-
Awesome, I'm glad you were able to learn something from it!
👍
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 63.5K Get Help
- 402 Global Discussions
- 213 Industry Talk
- 450 Announcements
- 4.7K Ideas & Feature Requests
- 141 Brandfolder
- 135 Just for fun
- 56 Community Job Board
- 454 Show & Tell
- 31 Member Spotlight
- 1 SmartStories
- 296 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!