Excel - Count if a value is unique and a different value is greater than 1 -


i have list of identifiers, transaction amounts, , number of transactions @ amount. identifiers repeat if transaction amount differs, , need count of identifiers appear once, , number of transactions @ amount equal one.

so if

  • bob had 1 transaction @ $45.00
  • sally had 3 transactions @ $36.00, 1 transaction @ $22.00, , 2 transactions @ $50.00
  • john had 1 transaction @ $25.00 , 1 transaction @ $67.00
  • mark had 1 transaction @ $25.00
  • tom had 7 transactions @ $23.00

the count return two.

to make answer easier follow, i've written example data out appear in excel, column letters , row numbers.

given following table:

           b        c 1   id       amount   count 2   bob      45       1     3   sally    36       3  4   sally    22       1  5   sally    50       2  6   john     25       1  7   john     67       1  8   mark     25       1  9   tom      23       7     

this formula give count of rows id appears once , once in id column, , value in count column equals 1.

=sum(if(if(c2:c9=1,1,0)+if(countif(a2:a9,a2:a9)=1,1,0)=2,1,0)) 

this array formula, once enter excel cell, instead of pressing enter, press ctrl+shift+enter.


Popular posts from this blog