Excel - Count unique values on multiple criteria

前端 未结 2 1095
猫巷女王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 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.

提交回复
热议问题