COUNTIF - with more than one criteria

K

Kathrine

I have a spreadsheet with a table where I want to count - but I have 2
criterias. How can I use this function with more than one criteria?

The spreadsheet looks something like this:

A B
1 Place Type of course
2 Oslo Intro
3 Stavanger Intro
4 Stavanger Theme
5 Oslo Theme
6 Stavanger Intro
7 Stavanger Intro
8 Bergen Theme
9 Bergen Intro


.... and so on

I want to count ex:
Oslo with intro
Oslo with theme
Bergen with intro
Bergen with theme
Stavanger with intro
Stavanger with theme

How can I do this in this function, or are there any other functions that
can be used? I can do this by filtering in a list with subtotal, but then I
have to change the filter all the time.
 
M

Max

Assume paired criteria listed in D2:E2 down
eg D2 = Oslo, E2 = Intro

Put in F2:
=SUMPRODUCT((A$2:A$100=D2)*(B$2:B$100=E2))
Copy down
 

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

Need Join help 0
Running two custom shows sequentially 4
Ignoring a runtime error 1
Find/replace numbers 2
Countif, IF condition is met 2
COUNTIF Function on filtered data 2
CountIf Query 1
Subtotal Countif 6

Top