Multiple COUNTIF formula

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

Guest

Hi

Can anyone assist with a multiple COUNTIF formula. I basically want to
count two values in a range of cells. At the moment Im putting in entering
something like -
=COUNTIF(C:C,"XXXX") AND COUNTIF(C:C,"YYYY").
However, this is not working so Im assuming I should be using a command
other than 'AND' to link them.

Any help advice appreciate. Thanks in advance!
 
A few ways:

To follow your lead, try this:

=COUNTIF(C:C,"XXXX")+COUNTIF(C:C,"YYYY")

To combine them, use the Sum() finction:

=SUM(COUNTIF(C:C,{"XXXX","YYYY"}))

Or, the ever popular<g> SumProduct():

=SUMPRODUCT(--(C1:C1000={"XXXX","YYYY"}))

--
HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================
 

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

Similar Threads

Excel Need Countifs Formula Help 0
COUNTIF using multiple criteria 5
Countif formula 2
Excel Use COUNTIF across a range of cells with formulas 0
Countif/Vlookup 2
Combining Percent with Text 5
Excel Count If Formula Question 1
Excel Copy COUNTIF while retaining reference 7

Back
Top