ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   SUM COUNTIF problem (https://www.excelbanter.com/excel-worksheet-functions/197364-sum-countif-problem.html)

AD Carvajal

SUM COUNTIF problem
 
In the following spreadsheet, I need to count the number of times "y" appears
in the Guest column when B appears in the Site column. Is there any way to
do this with one formula

Site Guest
E n
E n
E n
E n
E n
E n
E n
E n
E y
E n
B n
B n
B y
B y
E n
E n
E y
E y
E n
E n
A n
A n
A y
A y
A n


T. Valko

SUM COUNTIF problem
 
Try this:

=SUMPRODUCT(--(A1:A25="B"),--(B1:B25="Y"))

--
Biff
Microsoft Excel MVP


"AD Carvajal" <AD wrote in message
...
In the following spreadsheet, I need to count the number of times "y"
appears
in the Guest column when B appears in the Site column. Is there any way
to
do this with one formula

Site Guest
E n
E n
E n
E n
E n
E n
E n
E n
E y
E n
B n
B n
B y
B y
E n
E n
E y
E y
E n
E n
A n
A n
A y
A y
A n





All times are GMT +1. The time now is 09:56 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com