Forum Discussion
jaolvera
Aug 16, 2023Brass Contributor
COUNT IF/AND formula
Hello! I need help with and IF/AND formula, I need a formula that will Count if column G is a “Resident”, and if any of the dates in Columns x, z, ab, ad, af, Ah, aj are 4 months from todays date, and if columns w, y, aa. Ac, ae, ag, ai contain either “Moderna bivalent” or “Pfizer Bivalent”.
- NikolinoDEGold Contributor
=COUNTIFS(G:G, "Resident",
(X:X>=TODAY()+120)*(X:X<=TODAY()+150),
(Z:Z>=TODAY()+120)*(Z:Z<=TODAY()+150),
(AB:AB>=TODAY()+120)*(AB:AB<=TODAY()+150),
(AD:AD>=TODAY()+120)*(AD:AD<=TODAY()+150),
(AF:AF>=TODAY()+120)*(AF:AF<=TODAY()+150),
(AH:AH>=TODAY()+120)*(AH:AH<=TODAY()+150),
(AJ:AJ>=TODAY()+120)*(AJ:AJ<=TODAY()+150),
W:W, "Moderna bivalent",
Y:Y, "Moderna bivalent",
AA:AA, "Moderna bivalent",
AC:AC, "Moderna bivalent",
AE:AE, "Moderna bivalent",
AG:AG, "Moderna bivalent",
AI:AI, "Moderna bivalent",
W:W, "Pfizer Bivalent",
Y:Y, "Pfizer Bivalent",
AA:AA, "Pfizer Bivalent",
AC:AC, "Pfizer Bivalent",
AE:AE, "Pfizer Bivalent",
AG:AG, "Pfizer Bivalent",
AI:AI, "Pfizer Bivalent")Hope this formula will help you.
My answers are voluntary and without guarantee!
- jaolveraBrass Contributor
this is great! I did get an error stating "Too few arguments" NikolinoDE I will attach workbook so you can see. I out the formula in the cell, its on the second tab.