Forum Discussion
IF FORMULA - Help Needed please
so my formula which works for the most part is
but it not showing Expired for any row
and if there is a completed expiry date in the past AND a pending in the future it says Compliant but it should say Pending
I would say, based on those concluding lines, that it's NOT working for the most part.
I truly don't have time to go through in depth and try to reconstruct. What I'd recommend is that you take each condition separately and make sure it is working before you string them together.
That is to say, look at each line in the formula as it's arrayed below. Work on each one separately, each in its own column. Combine them after each one is working.
I can tell you just looking at that first line under IFS, the one I've underlined, where you've put an AND condition inside an OR, that the OR is not working. Have you learned to count the pairs of parentheses? Count 1 for each open paren, subtract 1 for each closing paren. The count goes back to zero before any alternative (OR) condition is described..and then there's the "Not Completed" consequence.
=IFS(
OR(AND(ISBLANK(K4),ISBLANK(O4),ISBLANK(U4))),"Not Completed",
OR(K4>=TODAY()),"Compliant",
OR(AND(K4<TODAY(),OR(O4<TODAY(),ISBLANK(O4)),OR(U4<TODAY(),ISBLANK(U4)))),"Expired",
OR(AND(K4<TODAY(),O4>=TODAY())),"Pending",
OR(AND(K4<TODAY(),U4>=TODAY())),"Pending"
)
may need to do it another way