+ Reply to Thread
Results 1 to 8 of 8

Return value based upon lookup value and ranged date

  1. #1
    Forum Contributor
    Join Date
    12-20-2011
    Location
    United States, Ohio
    MS-Off Ver
    Excel 2010
    Posts
    295

    Question Return value based upon lookup value and ranged date

    Very hard to describe my struggle without posting an example, so I have simply explained it in the workbook. My hope is to do this without VBA.

    Range Lookup Value.xlsx

    In summary, I would like to return a value from a look-up table, based upon today's date, when the look-up table provides a date range (but return one row higher) when the date falls within a certain range.

    Again, I think the file explains it better.

    Thank you for your help and direction.

  2. #2
    Registered User
    Join Date
    07-03-2013
    Location
    Montreal, QC
    MS-Off Ver
    Excel 2010
    Posts
    61

    Re: Return value based upon lookup value and ranged date

    Try this

    =INDEX(E4:E21,MATCH(B1,B4:B21,1))

  3. #3
    Forum Contributor
    Join Date
    12-20-2011
    Location
    United States, Ohio
    MS-Off Ver
    Excel 2010
    Posts
    295

    Re: Return value based upon lookup value and ranged date

    Quote Originally Posted by Gottoplay View Post
    Try this

    =INDEX(E4:E21,MATCH(B1,B4:B21,1))
    Thanks for the reply Gottoplay. But that returns the value of E in the SAME row. I am looking for the value of E of the row above. For today, 820 should be returned. 880 is returned with your suggestion.

  4. #4
    Registered User
    Join Date
    07-03-2013
    Location
    Montreal, QC
    MS-Off Ver
    Excel 2010
    Posts
    61

    Re: Return value based upon lookup value and ranged date

    I did not see that you wanted the one above. You can use the same formula with one modification.

    =INDEX(E4:E21,MATCH(B1,B4:B21,1)-1)

    That should work

  5. #5
    Forum Contributor
    Join Date
    12-20-2011
    Location
    United States, Ohio
    MS-Off Ver
    Excel 2010
    Posts
    295

    Re: Return value based upon lookup value and ranged date

    I think a small variation gets me there:

    =INDEX(E4:E21,MATCH(B1,C4:C21,1))

  6. #6
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Return value based upon lookup value and ranged date

    Try this...
    =VLOOKUP($B$1,$C$4:$E$21,3,1)
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  7. #7
    Forum Contributor
    Join Date
    12-20-2011
    Location
    United States, Ohio
    MS-Off Ver
    Excel 2010
    Posts
    295

    Re: Return value based upon lookup value and ranged date

    Thanks to the both of you.

    I was making is much more difficult then needed. I forgot about the "1" value to be "largest value less than or equal to"

  8. #8
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Return value based upon lookup value and ranged date

    Happy to help and thanks for the feedback

+ 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. Replies: 10
    Last Post: 02-19-2013, 12:05 PM
  2. Replies: 1
    Last Post: 01-05-2011, 05:18 PM
  3. Replies: 0
    Last Post: 12-10-2010, 09:57 AM
  4. Lookup Two Named Ranged
    By yawnzzzz in forum Excel General
    Replies: 3
    Last Post: 09-24-2010, 03:10 PM
  5. Return count based on date lookup
    By stork22 in forum Excel General
    Replies: 1
    Last Post: 10-30-2009, 12:40 PM

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