+ Reply to Thread
Results 1 to 5 of 5

Head Count with countif condition

  1. #1
    Registered User
    Join Date
    11-29-2016
    Location
    India
    MS-Off Ver
    2010 2007
    Posts
    59

    Head Count with countif condition

    Hi,

    I've this following issue in head count with a formula.

    Col A (Month) Col B (Employee ID) Col C(Colutation Mr. / Ms.)

    What i need a employees count of men & women based on Mr. / Ms..

    Here I've repeated employees in each month.

    Could some one help me on this.

    Regards,
    Vcare

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    79,383

    Re: Head Count with countif condition

    So you want a unique count of employee ID based on gender - correct?
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    79,383

    Re: Head Count with countif condition

    Try this for size (the dates column will be irrelevant):

    Excel 2016 (Windows) 32 bit
    L
    M
    N
    O
    P
    15
    1
    Mr
    16
    1
    Mr
    17
    1
    Mr Mr
    3
    18
    2
    Mr Ms
    2
    19
    2
    Mr
    20
    3
    Ms
    21
    3
    Ms
    22
    3
    Ms
    23
    4
    Ms
    24
    5
    Mr
    25
    5
    Mr
    Sheet: Sheet1

    Array formula:
    P
    17
    =SUMPRODUCT(IFERROR((1/COUNTIF($L$15:$L$25,$L$15:$L$25))*($M$15:$M$25=O17),0))
    Sheet: Sheet1

    ... confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer. Once confirmed, copy down.
    Last edited by AliGW; 01-04-2018 at 03:09 AM.

  4. #4
    Registered User
    Join Date
    11-29-2016
    Location
    India
    MS-Off Ver
    2010 2007
    Posts
    59

    Re: Head Count with countif condition

    Thank you AliGW

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    79,383

    Re: Head Count with countif condition

    You're welcome.

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Head count by department by date
    By SYOPS in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 04-06-2016, 06:39 PM
  2. Replies: 1
    Last Post: 12-17-2015, 11:22 AM
  3. [SOLVED] head swimming with countif
    By Mad Moose in forum Excel Formulas & Functions
    Replies: 17
    Last Post: 10-17-2015, 04:45 AM
  4. [SOLVED] SUMIF for head count
    By jackson_hollon in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 12-16-2014, 04:46 AM
  5. Formula for Changes in Head Count
    By bbarnett in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-30-2012, 12:41 PM
  6. Head Count by criteria
    By eshen in forum Excel Programming / VBA / Macros
    Replies: 22
    Last Post: 05-12-2010, 11:40 AM
  7. head count on rota
    By nick in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 03-09-2005, 04:06 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1