The COUNTIFS function
Counting the rows that meet several criteria at once: North orders delivered in March.
Syntax
=COUNTIFS(criteria_range1, criteria1, [criteria_range2, criteria2], …)
In a French Excel: =NB.SI.ENS(plage_critères1; critère1; [plage_critères2; critère2]; …).
Arguments
- criteria_range1, criteria1…: pairs of tested column and criterion, all required.
An example
=COUNTIFS(A:A,"North",B:B,"Delivered")
The number of North orders that are delivered.
Pitfalls
- Ranges of different sizes: #VALUE!.
- Criteria combine with AND: for an OR, add two COUNTIFS.
Going further
- COUNTIF.
- SUMIFS.
- Column profile: a column's values and their counts, with no formula.
Frequently asked questions
- How do I count between two dates?
=COUNTIFS(C:C,">="&E1,C:C,"<="&E2), with the two dates in E1 and E2.