Excel - Count unique values on multiple criteria

前端 未结 2 1097
猫巷女王i
猫巷女王i 2021-01-23 11:37

My head is just sort of spinning on this and the solution examples. Can someone please provided a solution for this specific issue? Once I see it for what I need then it click

相关标签:
2条回答
  • 2021-01-23 11:59

    use:

    =SUMPRODUCT(((D2:D8="ACH")*(E2:E8="FRAUD"))/(COUNTIFS(C:C,C2:C8,D:D,"ACH",E:E,"FRAUD")+(D2:D8<>"ACH")+(E2:E8<>"FRAUD")))
    

    0 讨论(0)
  • 2021-01-23 12:03

    This is essentially the same method as the response from Scott Craner but incorporates dynamic column length.

    =SUMPRODUCT(((D$2:INDEX(D:D, MATCH(1E+99, C:C))=H2)*(E$2:INDEX(E:E, MATCH(1E+99, C:C))=I2))/
                (COUNTIFS(C$2:INDEX(C:C, MATCH(1E+99, C:C)), C$2:INDEX(C:C, MATCH(1E+99, C:C)),
                          D$2:INDEX(D:D, MATCH(1E+99, C:C)), H2, E$2:INDEX(E:E, MATCH(1E+99, C:C)), I2)+
                (D$2:INDEX(D:D, MATCH(1E+99, C:C))<>H2)+(E$2:INDEX(E:E, MATCH(1E+99, C:C))<>I2)))
    

    This formula's dynamic column length does depend on the accounts being true numbers.

    0 讨论(0)
提交回复
热议问题