Forum Discussion
LisaSingleton
Oct 08, 2024Brass Contributor
Help with If/And function
Trying to calculate the age of a closed item and getting errors with the below formula. The objective is to calculate how long it took for an item to close (filtering on Closed items only). Thanks ...
- Oct 08, 2024
=IF(AND(I68="Closed",M68<>""),M68-Q68,TODAY()-Q68)
Does this work in your sheet? However it's better to share an example without sensitive data which shows the sample data along with the expected result.
LisaSingleton
Oct 14, 2024Brass Contributor
Thanks for your reply. Per sample table below, I would like to calculate the age of an item as long as it's open, but once status is "closed" would like calculation to stop. Expected result is reflected in last row, where item closed on 10/1 and eventhough today is 10/14, the days calculated is 20.
| Status | Created date | Date last updated | |
| Pending | 8/9/2024 | 9/30/2024 | 66 |
| New | 9/1/2024 | 43 | |
| Closed | 9/11/2024 | 10/1/2024 | 20 |
NikolinoDE
Oct 14, 2024Platinum Contributor
=IF(A2="Closed", C2-B2, TODAY()-B2)
Example file is inserted.
My answers are voluntary and without guarantee!
Hope this will help you.