COUNT IF duration between two dates & return 0 if one column is blank

I'm trying to count a cell if it meets the following criteria:
Termed Date - Hired Date = > Hired Date
or
if Termed Date is blank, count if Hired Date = > today's date
Answers
-
hi @ralter,
you can use nested if function witht he isblank function.
=if(ISBLANK(tdate@row), 1, if(tdate@row>=hdate@row, 1, 0)) its not exact function but the direction you shall go…
Experienced IT PM and the Real Smartsheet Enthusiast.
Is there anything else we can help you with? - book your time.
MASA Consult - Your Aligned Smartsheet Gold Partner
Find us on LinkedIn & Check our Smartsheet Solutions!
Tag my name: @kowal if you want me to respond :)
-
Are you able to provide some screenshots for context?
-
Sure! Thanks for your help!
I should clarify what I'm trying to solve,
Count if Termed Date is blank, but Hired Date is at least 31 days ago from today or
Count if Termed Date from Hired Date is at least 31 days between each dates -
OkI think I may have figured it out.
=IF(NOT(ISBLANK([Hired Date]@row)), IF(OR([Termed Date]@row = [Hired Date]@row + 31, AND(ISBLANK([Termed Date]@row), [Hired Date]@row + 31 <= TODAY())), 1, 0), 0) -
Glad you were able to get it sorted.
My personal approach would have been:
=IF([Hired Date]@row <> "", IF(IF([Termed Date]@row <> "", [Termed Date]@row, TODAY()) - [Hired Date]@row >= 31, 1))
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 67.2K Get Help
- 451 Global Discussions
- 155 Industry Talk
- 505 Announcements
- 5.4K Ideas & Feature Requests
- 85 Brandfolder
- 156 Just for fun
- 80 Community Job Board
- 514 Show & Tell
- 34 Member Spotlight
- 2 SmartStories
- 308 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!