+ Reply to Thread
Results 1 to 4 of 4

# age entries after sort of column

  1. #1
    Registered User
    Join Date
    12-19-2011
    Location
    Copenhagen
    MS-Off Ver
    Excel 2007 - 2010
    Posts
    2

    Question # age entries after sort of column

    Hi all,

    I'm making a members list for a club, using Excel 2010.
    The function I'm interested in is as follows:

    I have a column containing birthdays of the members
    below the column, I have a cell in which any date can be entered manually. This is the "final date"

    Now, based on this "final date", I'd like to output (in an output cell) the amount of members who's age is 25 or less. (and another cell with age 26+)

    I have tried the following:
    Please Login or Register  to view this content.
    where R5:R13 are the column containing the birthdays, and R16 containing the "final date".

    I'm getting no errors in the function, but I get a total of 0 members in the output cell...
    Is it correct to use COUNTIFS? - What else could/should I try to make this work?

    Please do ask, if something isn't clear enough.

    Thanks in advance for any constructive answer/suggestion!
    Last edited by boomla; 12-19-2011 at 11:00 PM. Reason: Solved

  2. #2
    Forum Guru
    Join Date
    05-24-2011
    Location
    India
    MS-Off Ver
    365
    Posts
    2,243

    Re: # age entries after sort of column

    Try this,

    26+,

    =SUMPRODUCT(--(EDATE(R16,-26*12)>=R5:R13),--(R5:R13>0))

    <=25,

    =SUMPRODUCT(--(EDATE(R16,-25*12)<=R5:R13),--(R5:R13>0))
    Regards,
    Haseeb Avarakkan

    __________________________________
    "Feedback is the breakfast of champions"

  3. #3
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,792

    Re: # age entries after sort of column

    You could use COUNTIF then you don't need the >0 check, e.g. for those who haven't yet reached their 26th birthday on R16 date

    =COUNTIF(R5:R13,">"&EDATE(R16,-26*12))
    Audere est facere

  4. #4
    Registered User
    Join Date
    12-19-2011
    Location
    Copenhagen
    MS-Off Ver
    Excel 2007 - 2010
    Posts
    2

    Re: # age entries after sort of column

    Quote Originally Posted by Haseeb A View Post
    Try this,

    26+,

    =SUMPRODUCT(--(EDATE(R16,-26*12)>=R5:R13),--(R5:R13>0))

    <=25,

    =SUMPRODUCT(--(EDATE(R16,-25*12)<=R5:R13),--(R5:R13>0))

    First off - Im a bit surprised...
    So short time, yet 2 suggestions - very nice

    Secondly, Haseeb - you got the "most right" solution for me.
    Meaning, that replacing the "," with ";" made the trick just right (using Excel 2010)

    Thank you both, much appreciated!
    boomla

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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