COUNTIF Multiple Conditions

P

Paul Sheppard

How do I use countif with multiple conditions

Column B has dates
Column C has Various data or Blank

I need to count the number of non blanks in column C if column A is one
of 3 dates

I have tried the array formula below, but am getting the wrong answer

{=SUM((Sheet1!$B$2:$B$100=A6)*(Sheet1!$B$2:$B$100=A7)*(Sheet1!$B$2:$B$100=A8)*(Sheet1!$C$2:$C$100<>""))}

A6, A7 and A8 are the cells witth the dates in
 
R

Rowan

=SUM(((Sheet1!$B$2:$B$100=A6)+(Sheet1!$B$2:$B$100=A7)+(Sheet1!$B$2:$B$100=A8))*(Sheet1!$C$2:$C$100<>""))

array entered with Ctrl+Shift+Enter

or entered normally

=SUMPRODUCT((($B$2:$B$100=A6)+($B$2:$B$100=A7)+($B$2:$B$100=A8))*($C$2:$C$100<>""))

Hope this helps
Rowan
 
D

Don Guillett

or slightly shorter might work

=SUMPRODUCT(($B$2:$B$100=A6)*($B$2:$B$100={A7,a8})*($C$2:$C$100<>""))

--
Don Guillett
SalesAid Software
(e-mail address removed)
=SUM(((Sheet1!$B$2:$B$100=A6)+(Sheet1!$B$2:$B$100=A7)+(Sheet1!$B$2:$B$100=A8
))*(Sheet1!$C$2:$C$100 said:
array entered with Ctrl+Shift+Enter

or entered normally
=SUMPRODUCT((($B$2:$B$100=A6)+($B$2:$B$100=A7)+($B$2:$B$100=A8))*($C$2:$C$10
 
D

Domenic

Maybe...

=SUMPRODUCT(--(ISNUMBER(MATCH(Sheet1!$B$2:$B$100,A6:A8,0))),--(Sheet1!$C$
2:$C$100<>""))

Hope this helps!

Paul Sheppard
 
C

cchen212

Hello

I want to count everything in Column K that is either greater than or
to 75% AND less than or equal to 125%. Is there a way to do this?

This is the formula i used and it works but it seems a bit lon
winded.

thanks

=COUNT(K3:K29)-COUNTIF(K3:K29,"<75%")-COUNTIF(K3:K29,">125%"
 
P

Peo Sjoblom

=COUNTIF(K3:K29,">=0.75")-COUNTIF(K3:K29,">1.25")

or

=SUMPRODUCT(--(K3:K29>=0.75),--(K3:K29<=1.25))

will both retrun the same count
 

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