COUNTIFS Error when using IFERROR
Hello,
I am trying to use the COUNTIFS formula in a sheet where I need the formula to count all cells with the value matching the Claim Status value, within the month and year stated in the next column, but the formula keeps breaking when i add in the Claim Status as a condition to look for.
Does anyone know how this can be fixed to include all of the below conditions:
- The month of the "Target Close Out Date" matches the month in the current row.
- The year of the "Target Close Out Date" matches the year in the current row.
- The "Claim Status" matches the value in the current row
This is the formula that im trying to get to count:
=COUNTIFS({Claim Status}, IFERROR([Claim Status]@row, 0), {Target Close Out Date}, IFERROR(MONTH(@cell), 0) = Months@row, {Target Close Out Date} IFERROR(YEAR(@cell), 0) = Year@row)
Look forward to hearing a solution! :)
Best Answer
-
Hi
I think the IFERROR on your Claim Status is going to cause a problem and you don't actually need one as a missing Claim Status should not cause an error in the way a missing date will. Try removing it. You also need a comma before the final IFERROR.
=COUNTIFS({Claim Status},[Claim Status]@row, {Target Close Out Date}, IFERROR(MONTH(@cell), 0) = Months@row, {Target Close Out Date}, IFERROR(YEAR(@cell), 0) = Year@row)
Answers
-
Hi
I think the IFERROR on your Claim Status is going to cause a problem and you don't actually need one as a missing Claim Status should not cause an error in the way a missing date will. Try removing it. You also need a comma before the final IFERROR.
=COUNTIFS({Claim Status},[Claim Status]@row, {Target Close Out Date}, IFERROR(MONTH(@cell), 0) = Months@row, {Target Close Out Date}, IFERROR(YEAR(@cell), 0) = Year@row)
-
How do you have your date captured in the Target Close out date? Do you have Month and Year columns created in your source sheet based on your Target Close Out Date?
Thanks,
Aravind GP| Principal Consultant
Atturra Data & Integration
M: +61493337445
E:Aravind.GP@atturra.com
W: www.atturra.com
-
Thank @KPH!
That worked!
-
Wonderful! Thanks for letting me know.
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 65.2K Get Help
- 445 Global Discussions
- 143 Industry Talk
- 476 Announcements
- 5K Ideas & Feature Requests
- 84 Brandfolder
- 150 Just for fun
- 71 Community Job Board
- 488 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 301 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!