xl-central.com, Your Quick Reference to Excel Solutions





navleft
navright
spacer

Count based on Multiple Criteria

Count based on Multiple Criteria

The following formula counts the number of times a value in B2:B10 equals the value in E2, and the corresponding value in C2:C10 equals the value in F2...

=COUNTIFS(B2:B10,E2,C2:C10,F2)

For versions prior to Excel 2007 for the PC and Excel 2008 for the Mac:

=SUMPRODUCT(--(B2:B10=E2),--(C2:C10=F2))

Based on the sample data, the formulas return 2.  Sample Workbook



spacer
Wu Yi Tea
Website Designed by Wu Yi Tea
Design downloaded from free website templates.
Wordpress Themes