+ Reply to Thread
Results 1 to 8 of 8

How to total vaules over a date range...

  1. #1
    Registered User
    Join Date
    03-29-2014
    Location
    Orlando
    MS-Off Ver
    Excel 2003
    Posts
    3

    How to total vaules over a date range...

    Hi!

    I am trying to figure out how I can total a tally of counts that fall over a date range. I'm sure there is a way but I am not that educated in excel to execute.

    Basically, my data is hotel reservation room nights:

    ARRIVAL_DATE DEPARTURE_DATE NIGHTS
    13-Apr-14 20-Apr-14 7
    13-Apr-14 15-Apr-14 2


    I need to the number of room nights over a 90 day period for 1000s of reservations filled in like so:
    Date 13-Apr 14-Apr 15-Apr 16-Apr 17-Apr 18-Apr 19-Apr 20-Apr
    Total Number of Room Nights 2 2 1 1 1 1 1 0


    I sure there is a fairly simple way to accomplish, but I can't figure it out. Anyone have any ideas?


    Thanks!
    Last edited by Jonbones22; 03-29-2014 at 11:45 AM.

  2. #2
    Forum Expert
    Join Date
    12-11-2011
    Location
    Netherlands
    MS-Off Ver
    office 365
    Posts
    3,654

    Re: How to total vaules over a date range...

    Without a xls sample I should say try one of these:
    sumif
    sumifs
    sumproduct
    pivot table
    Willem
    English is not my native language sorry for errors
    Please correct me if I'm completely wrong

  3. #3
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: How to total vaules over a date range...

    You are probably looking at something like this:
    Attached Files Attached Files
    <---------If you like someone's answer, click the star to the left of one of their posts to give them a reputation point for that answer.
    Ron W

  4. #4
    Registered User
    Join Date
    03-29-2014
    Location
    Orlando
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: How to total vaules over a date range...

    This will actually help in a different project I have, thanks! I need to know how many rooms nights total each date in the time period. Example would be when I have two reservations A: 4/13 - 4/15 (2 nights) and B: 4/13 -4/20 (7 nights) the total for each date would be 4/13 -2 rn (room night), 4/14 - 2 rn, 4/15 - 1 rn, 4/16 - 1rn, 4/17 -1 rn, 4/18 - 1 rn, 4/19 - 1 rn, 4/20 - 0 rn.

    Since the departure date does not include a room night, I'm guessing an adjustment of -1 needs to be added. Or remove departure date from the equation i guess...


    I've updated the original post with better description of data and layout.



    Thanks!
    Last edited by Jonbones22; 03-29-2014 at 11:50 AM.

  5. #5
    Registered User
    Join Date
    03-29-2014
    Location
    Orlando
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: How to total vaules over a date range...

    Book3.xlsx

    Here is exampe of data.

  6. #6
    Forum Expert
    Join Date
    12-11-2011
    Location
    Netherlands
    MS-Off Ver
    office 365
    Posts
    3,654

    Re: How to total vaules over a date range...

    Maybe this?
    Attached Files Attached Files

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

    Re: How to total vaules over a date range...

    Assuming your calendar dates start from G1 and accross
    Type in G2 and drag accross:
    =SUMPRODUCT(($A$2:$A$22<=G$1)*($B$2:$B$22>G$1))
    Quang PT

  8. #8
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: How to total vaules over a date range...

    Countifs also works with your chart. For easy comparison, I put your chart in the same location as bebo021999.

    Formula: copy to clipboard
    Please Login or Register  to view this content.

+ 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. Total Monthly Hours from a date range rollup
    By crab007 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-25-2012, 06:14 AM
  2. Total values from date range table
    By MrFoxar in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-10-2009, 04:49 PM
  3. Changing vaules according to date selected
    By Dan Mackman in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 07-26-2007, 03:14 PM
  4. Replies: 1
    Last Post: 05-17-2005, 03:06 PM
  5. [SOLVED] How to total itmes if they fall between a date range
    By cel in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-17-2005, 03:06 PM

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