CountIF Function

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How Can I have multiple condition using countif function.
Ex: If I want to count only those cells that have value >300 and <700
 
Hi

You can use Sumproduct:

=SUMPRODUCT((A1:A100>300)+0,(A1:A100<700)+0)

Note that you can't use whole column refs with sumproduct though (ie
so no A:A - the max is A1:A65536).

Alternatively, you could use COUNTIF:

=SUM(COUNTIF(A:A,{">300",">=700"})*{1,-1})

Hope this helps!

Richard
 
Hi,
It worked, Thanks
How can we use the same countif function or any other function if we are
wrking with dates or strings.
Ex: to count cells between 2 set of dates or to count cells that match
string('sale' or 'quote')
 

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

Back
Top