Counting a Unique identifier in a column

Hello SS Community,

I am halfway there but seem to be doing something wrong- I want to count how many times a Person shows up in the list and record the number.

I have this formula =IF(COUNTIF([Person Number]:[Person Number], [Person Number]@row) > 1, 1) and it is working perfectly to record when the person number in the Person number column shows up more than once but when I add the second layer to record two when the person number shows more than two =IF(COUNTIF([Person Number]:[Person Number], [Person Number]@row) > 1, 1) IF(COUNTIF([Person Number]:[Person Number], [Person Number]@row) > 2, 2)) It does not do anything and still records 1 even when the exact person number is in the column twice.

I also tried to use this formula =COUNTIF([Person Number]:[Person Number], [Person Number]@row) which worked but the reason I can't use this is I don't want to count the first occurrence of the person number in the sheet- I am trying to use it to count how many times the person number was rescheduled, so the first occurrence should be removed from the count.

Best Answer

  • Heather Duff
    Heather Duff ✭✭✭✭✭✭
    Answer ✓

    @Omotola Ashafa ,

    Try this, then:

    =if(COUNTIF([Person Number]:[Person Number], [Person Number]@row)>1,COUNTIF([Person Number]:[Person Number], [Person Number]@row)-1,"")

    Really all you're doing is subtracting 1 from the count if it qualifies, but it should do the trick!

Answers

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!