Sum most recent value by reference criteria

jamesfbuk

New Member
Joined
Dec 10, 2015
Messages
3
Hi,

I have a set of data as below, with values for individual references for each quarter. These may be updated on a weekly basis.

Data
RefDateQ1Q2Q3
L101/01/2015111
L201/01/2015222
L301/01/2015333
L401/01/2015444
L501/01/2015555
L601/01/2015666
L701/01/2015777
L801/01/2015888
L308/01/2015357
L408/01/2015468
L508/01/201551015
L515/01/2015678
L615/01/2015789
L715/01/2015101010

<tbody>
</tbody>

I'm looking to put together a summary table which can be defined by the date as to what data is pulled in, i.e. if the date were 1/1/15 then the result would simply be identical to the first 8 rows. If it were changed to the 15/1/15, then it would be as below:

Desired Result
Q1Q2Q3
L1111
L2222
L3357
L4468
L5678
L6789
L7101010
L8888

<tbody>
</tbody>

I have the formula to put together the discrete list of references, but can't put together the formula to pull in the data. I'm assuming some form of sumproduct with a max reference in, but can't get there. Help massively appreciated.

Many thanks.
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!
Have made a potential bit of progress, using Mr Fairwinds answer to this:

http://www.mrexcel.com/forum/excel-questions/201255-vlookup-last-match.html

Based on the data above, the formula =LOOKUP(2,1/(Reference=$A2),C$2:C$15) has produced a table with the latest data, where 'Reference' is a named range for A2:A15 (i.e. all of the L1, L2, etc.).

If I'm able to create a dynamic named range for the Reference element based on the dates (which should be in descending order), and based on a cell reference into which the desired date boundary can be input, I think that might work. Not certain mind!

Any alternatives or continuations on this theme still very gratefully received.
 
Upvote 0
Now resolved, using dynamic reference instead of the locked 'Reference' as per last post. Dynamic reference created using Index - Match, altered to match this data would be:

=A2:INDEX(A:A,MATCH(*Date*,B2:B15,1)+1)

where *Date* is the desired date boundary (likely as a cell reference). The +1 at the end of the Index accounts for the Header line.

Thanks to those who reviewed this and tried to come up with a solution- would still be interested in alternatives from an academic perspective, or something that might process quicker (spreadsheet at the moment quite small, so don't know how this will run with much larger data yet).
 
Upvote 0

Forum statistics

Threads
1,222,091
Messages
6,163,861
Members
451,861
Latest member
Lurch65

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top