COUNTIF for two criterias

D

dterest

Hello,

I would like to use the countif function but using two criterias.
For example:

I want to count the times the string X appears on column B for
certain criteria in column A.

A B

1 X
1
1 X
1 X
1
2 X

In this case I would like to count the X's matching the value in colum
A = 1, the result should be 3.
Does anyone know, how to do this?
Thanks in advance for any help
 
A

Amy Cox

Hi,

This is an array formula and would need to be entered as
follows:

=SUM((A1:A10=1)*(B1:B10="x"))

Since this is an array formula rather than hitting enter
once you have completed the formula you must press
Ctrl+Shift+Enter.

Good luck!
Amy Cox
Replacements, Ltd.
1-800-REPLACE
 
F

Frank Kabel

Hi
you probably meant:
SumProduct((B1:B10="X")*(A1:A10=1))

(corrected some typos and missing brackets)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top