ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Count if - 2 conditions (https://www.excelbanter.com/excel-discussion-misc-queries/175638-count-if-2-conditions.html)

orquidea

Count if - 2 conditions
 
Hi:

How would I write A "COUNT IF AND" formula? I tried

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"), but there is an error somewhere.

Thanks in advance.
Escarly


T. Valko

Count if - 2 conditions
 
COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"),

It depends on how you want this to count. You're referencing a 2 column
range with B5:C30. What result do you expect with this sample:

......B.....C.....E
......4.....4....Mama
......1.....4....Mama

Should the result be 2 or 3?

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
Hi:

How would I write A "COUNT IF AND" formula? I tried

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"), but there is an error
somewhere.

Thanks in advance.
Escarly




CLR

Count if - 2 conditions
 
=SUMPRODUCT((E5:E30="mama")*(C5:C30=4))

Vaya con Dios,
Chuck, CABGx3



"orquidea" wrote:

Hi:

How would I write A "COUNT IF AND" formula? I tried

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"), but there is an error somewhere.

Thanks in advance.
Escarly


CLR

Count if - 2 conditions
 
Good catch Biff...........I was reading out of my dominant eye again........<g

Vaya con Dios,
Chuck, CABGx3



"T. Valko" wrote:

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"),


It depends on how you want this to count. You're referencing a 2 column
range with B5:C30. What result do you expect with this sample:

......B.....C.....E
......4.....4....Mama
......1.....4....Mama

Should the result be 2 or 3?

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
Hi:

How would I write A "COUNT IF AND" formula? I tried

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"), but there is an error
somewhere.

Thanks in advance.
Escarly





orquidea

Count if - 2 conditions
 
I excpect 2, because rows have the 2 conditions "mama" and "4"

"T. Valko" wrote:

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"),


It depends on how you want this to count. You're referencing a 2 column
range with B5:C30. What result do you expect with this sample:

......B.....C.....E
......4.....4....Mama
......1.....4....Mama

Should the result be 2 or 3?

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
Hi:

How would I write A "COUNT IF AND" formula? I tried

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"), but there is an error
somewhere.

Thanks in advance.
Escarly





T. Valko

Count if - 2 conditions
 
Try this:

=SUMPRODUCT(--((B5:B30=4)+(C5:C30=4)0),--(E5:E30="mama"))

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
I excpect 2, because rows have the 2 conditions "mama" and "4"

"T. Valko" wrote:

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"),


It depends on how you want this to count. You're referencing a 2 column
range with B5:C30. What result do you expect with this sample:

......B.....C.....E
......4.....4....Mama
......1.....4....Mama

Should the result be 2 or 3?

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
Hi:

How would I write A "COUNT IF AND" formula? I tried

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"), but there is an error
somewhere.

Thanks in advance.
Escarly







orquidea

Count if - 2 conditions
 
thanks

"T. Valko" wrote:

Try this:

=SUMPRODUCT(--((B5:B30=4)+(C5:C30=4)0),--(E5:E30="mama"))

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
I excpect 2, because rows have the 2 conditions "mama" and "4"

"T. Valko" wrote:

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"),

It depends on how you want this to count. You're referencing a 2 column
range with B5:C30. What result do you expect with this sample:

......B.....C.....E
......4.....4....Mama
......1.....4....Mama

Should the result be 2 or 3?

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
Hi:

How would I write A "COUNT IF AND" formula? I tried

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"), but there is an error
somewhere.

Thanks in advance.
Escarly








T. Valko

Count if - 2 conditions
 
You're welcome!

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
thanks

"T. Valko" wrote:

Try this:

=SUMPRODUCT(--((B5:B30=4)+(C5:C30=4)0),--(E5:E30="mama"))

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
I excpect 2, because rows have the 2 conditions "mama" and "4"

"T. Valko" wrote:

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"),

It depends on how you want this to count. You're referencing a 2
column
range with B5:C30. What result do you expect with this sample:

......B.....C.....E
......4.....4....Mama
......1.....4....Mama

Should the result be 2 or 3?

--
Biff
Microsoft Excel MVP


"orquidea" wrote in message
...
Hi:

How would I write A "COUNT IF AND" formula? I tried

COUNT IF AND(E5:E30,"MAMA"),(B:5:C30,"4"), but there is an error
somewhere.

Thanks in advance.
Escarly











All times are GMT +1. The time now is 08:34 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com