+ Reply to Thread
Results 1 to 12 of 12

formula to identify week number based on date ranges and add values

  1. #1
    Registered User
    Join Date
    02-18-2014
    Location
    Orlando, Florida
    MS-Off Ver
    Excel 2003
    Posts
    8

    formula to identify week number based on date ranges and add values

    Hello,

    I have the following data:

    Column A = Date
    Column B = Reservations made per day
    for ex:

    A B
    1 3/1/2011 5
    2 4/5/2011 10
    3 3/8/2011 15

    Then I have a look up table where based on the date ranges it assigns a week number.

    Week DATE Range 1 Date Range 2
    7 18-Feb-11 24-Feb-11
    8 25-Feb-11 03-Mar-11
    9 04-Mar-11 10-Mar-11
    10 11-Mar-11 17-Mar-11
    11 18-Mar-11 24-Mar-11
    12 25-Mar-11 31-Mar-11
    13 01-Apr-11 07-Apr-11
    14 08-Apr-11 14-Apr-11
    15 15-Apr-11 21-Apr-11
    16 22-Apr-11 28-Apr-11

    I am looking for a fomula that would assign a week to the corresponding dates on column A and tha would then add all of the reservations booked for each week.

    Thank you for your help.

  2. #2
    Forum Contributor thameem127's Avatar
    Join Date
    04-06-2012
    Location
    Jeddah,Saudi Arabia
    MS-Off Ver
    Excel 2003,Excel 2007
    Posts
    321

    Re: formula to identify week number based on date ranges and add values

    Upload your file.

  3. #3
    Forum Contributor
    Join Date
    01-22-2014
    Location
    genoa, italy
    MS-Off Ver
    Excel 2007
    Posts
    134

    Re: formula to identify week number based on date ranges and add values

    hi,
    does the attached file help?
    rgds,
    AL

    week.xlsx

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

    Re: formula to identify week number based on date ranges and add values

    Please Login or Register  to view this content.
    Quang PT

  5. #5
    Registered User
    Join Date
    02-18-2014
    Location
    Orlando, Florida
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: formula to identify week number based on date ranges and add values

    I have attached the file.
    Attached Files Attached Files

  6. #6
    Registered User
    Join Date
    02-18-2014
    Location
    Orlando, Florida
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: formula to identify week number based on date ranges and add values

    Thank you it worked!

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

    Re: formula to identify week number based on date ranges and add values

    Try in K2:
    Please Login or Register  to view this content.

  8. #8
    Forum Contributor thameem127's Avatar
    Join Date
    04-06-2012
    Location
    Jeddah,Saudi Arabia
    MS-Off Ver
    Excel 2003,Excel 2007
    Posts
    321

    Re: formula to identify week number based on date ranges and add values

    Check attached file.
    Attached Files Attached Files

  9. #9
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,446

    Re: formula to identify week number based on date ranges and add values

    And a Pivot Table will do it for you...

  10. #10
    Registered User
    Join Date
    02-18-2014
    Location
    Orlando, Florida
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: formula to identify week number based on date ranges and add values

    Thank you it worked. Would you be able to explain me a little what is this formula doing? Maybe by parts if at all possible
    I can see that it works, I just don't understand what I did. LOL
    Why do we multiply one piece by the other?

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

    Re: formula to identify week number based on date ranges and add values

    At least, can you let us know which solution work?
    I am happy to explain but i am not sure if it works

  12. #12
    Registered User
    Join Date
    02-18-2014
    Location
    Orlando, Florida
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: formula to identify week number based on date ranges and add values

    I apologize, I thought it could mark whcih post I was replying to.

    This solution worked:
    SUMPRODUCT(($E$2:$E$44>=VLOOKUP(J2,$A$1:$C$11,2,0))*($E$2:$E$44<=VLOOKUP(J2,$A$1:$C$11,3,0))*$F$2:$F$44)

+ 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. sum week to date values based on todays date
    By nicko54 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 08-19-2013, 07:48 PM
  2. [SOLVED] Date Formula to Return Week Number in Current Month based on Reporting Period
    By jeversf in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-25-2013, 12:10 PM
  3. week start date and end date based on week number
    By aman1234 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-02-2009, 12:39 PM
  4. updating a cell with a week number based on the system date
    By SRussell in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-05-2008, 03:14 PM
  5. Replies: 1
    Last Post: 08-23-2005, 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