+ Reply to Thread
Results 1 to 3 of 3

Revisit: Summing with date difference and conditions

  1. #1
    Registered User
    Join Date
    03-15-2011
    Location
    Iowa City, IA
    MS-Off Ver
    Excel 2013
    Posts
    29

    Question Revisit: Summing with date difference and conditions

    A month ago, Pete_UK solved a problem for me with this formula:

    =SUMPRODUCT((DATEDIF($B$2:$B$16,C$2:C$16,"m")>=$H2)*(DATEDIF($B$2:$B$16,C$2:C$16,"m")<$I2))

    The original problem was that I wanted to use a formula that will sum the date difference between each of the date columns and Client DOB by condition and put that information into tables. For example, I want to sum groups of "date diff" between client DOB and Client Intake by age categories by month:
    16-19 months
    20-25 months
    26-30 months
    and so on.

    The original solution worked fine for me until I have missing dates (formula turns to #num!). I tried various things, but nothing worked. I’ve attached the file. Is there a way to calculate this with missing dates?

    Thanks again

    Zeda
    Attached Files Attached Files

  2. #2
    Forum Expert CK76's Avatar
    Join Date
    06-16-2015
    Location
    ONT, Canada
    MS-Off Ver
    Office 365 ProPlus
    Posts
    5,883

    Re: Revisit: Summing with date difference and conditions

    Try...
    =SUMPRODUCT((IFERROR(DATEDIF($B$2:$B$16,C$2:C$16,"m")>=$H2,0))*(IFERROR(DATEDIF($B$2:$B$16,C$2:C$16,"m")<$I2,0)))

    Confirmed as array (CTRL+SHIFT+ENTER).

  3. #3
    Registered User
    Join Date
    03-15-2011
    Location
    Iowa City, IA
    MS-Off Ver
    Excel 2013
    Posts
    29

    Re: Revisit: Summing with date difference and conditions

    Worked beautifully. Thanks so much.

    Tamra

+ 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. [SOLVED] Summing with date difference and conditions
    By ZedaG in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 03-23-2017, 12:26 PM
  2. [SOLVED] SUMPRODUCT issue with summing based off date conditions
    By guitargod7277 in forum Excel General
    Replies: 6
    Last Post: 06-06-2012, 05:22 PM
  3. Find a folder by its name or wildcard (revisit)
    By bdb1974 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-07-2011, 12:55 PM
  4. Indirect with ActiveX Combobox (Revisit)
    By dagindi in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-12-2011, 01:39 PM
  5. Summing % Difference from in a Pivot Table
    By IW65537 in forum Excel General
    Replies: 0
    Last Post: 01-12-2009, 11:18 PM
  6. Summing by Date with discrete conditions
    By dulax in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-22-2008, 05:20 PM
  7. Replies: 5
    Last Post: 08-14-2007, 09:57 AM

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