Warning

 

Close
Confirm Action

Are you sure you wish to do this?

Cancel Confirm
AR15.COM
1/22/2007 8:22:45 AM EDT
I need to use a function that will return the total count of items in a column that meet a certain criteria, such as how many times a # 2 appears in a column, BUT I also need to vet that column against another column. I tried the COUNTIF with no success.

Here's what I want to do:

"Count the how many times the number 2 appears in column "V", but only if the value C appears in the same row in column "B"."

Make sense?
1/22/2007 10:08:07 AM EDT
[#1]

Quoted:
I need to use a function that will return the total count of items in a column that meet a certain criteria, such as how many times a # 2 appears in a column, BUT I also need to vet that column against another column. I tried the COUNTIF with no success.

Here's what I want to do:

"Count the how many times the number 2 appears in column "V", but only if the value C appears in the same row in column "B"."

Make sense?


Here's a simple way, but it requires another column...

Paste the following formula into the top cell (matching your existing data).  Change the row number to match and then copy it down to the bottom row....

=IF((AND(V1=2,B1="C")),1,0)

This will put a 1 in every row that contains the 2 and the C and a 0 in all the others.

Sum the column and you have your count.
1/23/2007 3:57:19 AM EDT
[#2]
That'll do it!  Thanks!