How to count “No” in column C base on Name & Id?

前端 未结 3 771
Happy的楠姐
Happy的楠姐 2021-01-25 05:07

I have 3 columns.

-----A-----B-----C-----
---Name----ID---Report

In column A I have Names(Can Repeat)
In column B I have IDs (can repeat wi

3条回答
  •  梦毁少年i
    2021-01-25 05:28

    This seems to be very close to what you are trying to do

    =SUMPRODUCT((A2:A1000="John")*(C2:C1000="No")*(IF(FREQUENCY(B2:B1000,B2:B999)>0,TRUE)))
    

    There is one flaw with the frequency in that it ignores the last row. If I change the frequency formula to FREQUENCY(B2:B1000,B2:B1000) it will error out as it returns 10 results instead of the desired 9.

    EDIT

    It is probably better to extend the other ranges than shorten the bins array.

    =SUMPRODUCT((A2:A1001="John")*(C2:C1001="No")*(IF(FREQUENCY(B2:B1001,B2:B1000)>0,TRUE)))
    

提交回复
热议问题