+ Reply to Thread
Results 1 to 3 of 3

Sumif between date ranges depending on condition

  1. #1
    Registered User
    Join Date
    01-16-2020
    Location
    dc
    MS-Off Ver
    2013
    Posts
    5

    Sumif between date ranges depending on condition

    Good afternoon everyone !

    Here's the situation.

    The first sheet, SHEET A. I have a name column, and many date range columns going from 01/01/2015-01/31/2015 all the way to the present. This date range is the result of a formula I wrote. The names signify employees, and in the spaces under the date ranges, I want to put the total amount that employee spent in that time period, if they spent any.

    Name | 01/01/2015-01/31/2015 | 02/01/2015-02/28/2015 | ....
    Jeff
    Bob

    The data regarding spending comes from another sheet with three columns, which I will call SHEET B

    Name | Date | Amount Spent
    Jeff 01/15/2015 $15
    Jeff 01/24/2015 $30
    Bob 01/03/2015 $55
    Bob 02/04/2015 $10

    ...and so on and so forth.

    What I'm looking for is a formula which will calculate the total amount an employee spent in SHEET B in a given month and enter it into the appropriate cell in SHEET A based on the date ranges in the first row.

    I have attached a sample worksheet if the above is not a good description. Is this possible? Thanks.

    For transperancy sake here is the formula for the date ranges : =TEXT(DATE(2015,COLUMN(A:A),1),"MM/DD/YY")&"-"&TEXT(DATE(2015,COLUMN(A:A)+1,1)-1,"MM/DD/YY")
    Attached Files Attached Files

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,420

    Re: Sumif between date ranges depending on condition

    Why not make it easier on yourself and insert a Pivot Table?

    As it is, given the column headings you have created, any formula will be complex.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,463

    Re: Sumif between date ranges depending on condition

    In B2 then drag down and accross:

    Please Login or Register  to view this content.
    Attached Files Attached Files
    Quang PT

+ 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] Loop between date and make a sum depending condition
    By patronaja in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 10-28-2020, 10:35 AM
  2. [SOLVED] Copy Data from multiple worksheets depending on date condition
    By ghostly1 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 09-08-2015, 11:03 AM
  3. using sumif on different ranges depending on a date column
    By dwilkinson12 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 04-24-2013, 12:17 PM
  4. Adding up ranges depending on condition
    By sp_key in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 04-12-2013, 01:14 PM
  5. Formula using sumif depending on date in two cells
    By enhydra in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 11-19-2012, 04:27 AM
  6. how to count cells depending on date ranges?
    By jgomez in forum Excel General
    Replies: 1
    Last Post: 07-20-2011, 04:40 PM
  7. Calculate depending on date ranges
    By vicstone in forum Excel General
    Replies: 2
    Last Post: 07-27-2010, 11:42 AM

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