|
Question : Nested countif problem
|
|
If I wanted to count the rows in column A that has a "wa" in them and if column B on that same row =3806 how would I do that. CountIF wont allow two different criterian. Would you combine a IF(countif) or what. Please help....Thank you. Sample;
Col_A Col_B WS 3806 TU 4545 WS 4343 WS 3806
count= two rows that meet the above criteria. WS and 3806 on the same row.
|
|
Answer : Nested countif problem
|
|
One way around it is to do this:
WS 3806 1 TU 4545 0 WS 4343 0 WS 3806 1 2
The formula for that is:
WS 3806 =IF(AND(A1="WS", B1=3806),1,0) TU 4545 =IF(AND(A2="WS", B2=3806),1,0) WS 4343 =IF(AND(A3="WS", B3=3806),1,0) WS 3806 =IF(AND(A4="WS", B4=3806),1,0) =SUM(C1:C4)
And if you wanted to you could simply hide the third, "extra" column.
:o)
Ant
|
|
|
|