Forum Discussion

hurshie's avatar
hurshie
Copper Contributor
Jun 04, 2020

EXCEL FORMULA HELP

Hello,

 

I am trying to count headcount but cant seem to count unique values.

 

example: Below is the text that i need a countif headcount and i cant seem to get unique values. If there are duplicates I only wan to have it count onces. How do I do that?

Hursh Serv
Hursh Serv
Hursh Serv
Peanut nj
Henry mo
Anthony mo
Anthony mo
Anthony mo
David Serv
David Serv

15 Replies

  • JMB17's avatar
    JMB17
    Bronze Contributor

    =sumproduct(1/countif(a1:a10,a1:a10&""))

    if you want to exclude blank cells
    =sumproduct((a1:a10<>"")/countif(a1:a10,a1:a10&""))

    • hurshie's avatar
      hurshie
      Copper Contributor

      IngeborgHawighorst 

       

      unfortunately, i do not have the Unique function tool as of yet. I guess my explination was not correct.

       

      I need to find the total unique text and a count of location:

      I know that there are 5 unique values but needs to break down like this.

       

       

      NameLocation  Total Number of
      hurshServ Serv?
      hurshServ NJ?
      peanutnj MO?
      Kevinnj   
      Alexmo   
      Henrmo   
      TomServ   
      peanutnj   
      hurshServ   
      Henrmo   
      • Jos_Woolley's avatar
        Jos_Woolley
        Iron Contributor

        hurshie 

         

        Array formula (CTRL+SHIFT+ENTER) in F2:

         

        =SUM(IF(FREQUENCY(IF(B$2:B$11=D2,MATCH(A$2:A$11,A$2:A$11,0)),ROW(A$2:A$11)-MIN(ROW(A$2:A$11))+1),1))

         

        and copied down.

         

        Regards

Resources