Help with Formula
Could someone please help me with a formula?
Basically I want a formula to return a "Yes" if any data in the Area column = Location 1, but between a specified date range. If Location 1 is not in the area column, then return a "No". Thank you.
Best Answer
-
I came up with this formula and it worked for me when I tested it out. Go ahead and give it a shot and let me know if it doesn't work for you.
=IF(AND(HAS(Area@row:Area@row, "Location 1"), NETDAYS([Start Date]@row, [End Date]@row) > 0) = true, "Yes", "NO")
Answers
-
I came up with this formula and it worked for me when I tested it out. Go ahead and give it a shot and let me know if it doesn't work for you.
=IF(AND(HAS(Area@row:Area@row, "Location 1"), NETDAYS([Start Date]@row, [End Date]@row) > 0) = true, "Yes", "NO")
-
If your sheet has only one date column, then you could do something like this:
=IF(AND(HAS(Area@row:Area@row, "Location 1"), [Date]@row >= TODAY(-7)) = true, "Yes", "NO")
This will check to see if the date is within the last 7 days.
OR convert the date to a 1-52 weeknumber to determine if the date entered is greater or less than that week.
=IF(AND(HAS(Area@row:Area@row, "Location 1"), WEEKNUMBER([Date]@row) < 40) = true, "Yes", "NO"
-
Thanks Jeff M. That worked!
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 62.8K Get Help
- 376 Global Discussions
- 207 Industry Talk
- 440 Announcements
- 4.5K Ideas & Feature Requests
- 139 Brandfolder
- 129 Just for fun
- 130 Community Job Board
- 449 Show & Tell
- 30 Member Spotlight
- 1 SmartStories
- 284 Events
- 33 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!