Forum Discussion
LindsayLindsay
May 19, 2023Copper Contributor
Excel CountIf, plus second statement
I have two columns of data, please note not all rows have data inputted (i.e. Row 1 could have data in Column 1&2, Row 2 has data in Column 1 but not Column 2, and Row 3 has data in Column 2 but not Column 1, etc.).
Column A is text holding provincial acronyms (2 letters such as AB, SK, BC, etc.), Column B is Accounting with $.
In my other table, I want to COUNT Column B IF there is a $ value but only count if Column A equals a certain value (ex: AB).
Example, COUNT cells in Column B where $ is greater than 0 IF the corresponding Row in Column A equals "AB
- jitinmIron Contributor
=COUNTIFS(A2:A1000, "AB", B2:B1000, ">0")
Adjust the ranges as needed (it doesn't matter if they include more cells than are in use).