Forum Discussion

Alex_Maslovskiy's avatar
Alex_Maslovskiy
Copper Contributor
Jun 22, 2020
Solved

Error in distinct values formula

Attached file contains list of numbers in column A and a formula to check, if a number is distinct, in column B.  In some cases, the formula doesn't work as expected. For instance, line 2961 contain...
  • SergeiBaklan's avatar
    Jun 22, 2020

    Alex_Maslovskiy 

    Alex, I opened your file and see the correct result

    Are you on automatic calculation option?

     

    In general, since COUNTIF() converts texts which represent numbers into numbers, perhaps it'll be more reliable to use SUMPRODUCT() here

    =IF(SUMPRODUCT(1*(A$2:A2961=A2961))=1,1,0)
    or
    =--(SUMPRODUCT(1*(A$2:A2961=A2961))=1)

Resources