Return last value in a list based on a given condition (Month)

steveh1873

New Member
Joined
Aug 28, 2014
Messages
17
DateMonthTotal
19/07/2015

<tbody>
</tbody>
July

<tbody>
</tbody>
392

<tbody>
</tbody>
26/07/2015

<tbody>
</tbody>
July

<tbody>
</tbody>
409

<tbody>
</tbody>
02/08/2015

<tbody>
</tbody>
August

<tbody>
</tbody>
416

<tbody>
</tbody>
09/08/2015

<tbody>
</tbody>
August

<tbody>
</tbody>
383

<tbody>
</tbody>
16/08/2015

<tbody>
</tbody>
August

<tbody>
</tbody>
363

<tbody>
</tbody>
23/08/2015

<tbody>
</tbody>
August

<tbody>
</tbody>
290

<tbody>
</tbody>
30/08/2015

<tbody>
</tbody>
August

<tbody>
</tbody>
351

<tbody>
</tbody>
06/09/2015

<tbody>
</tbody>
September

<tbody>
</tbody>
362

<tbody>
</tbody>
13/09/2015

<tbody>
</tbody>
September

<tbody>
</tbody>
354

<tbody>
</tbody>

<tbody>
</tbody>

Hi there,

Using the above table, what formula can I use to return the last value in the total column, that is the latest figure for the month, please?

i.e. for July it should be - 409, August - 351 and September - 354.

If i create a table listing all the months, i'd like to know the last value (chronologically) for each month.

Thanks in advance.

Steve
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
=INDEX(C$1:C$9,MATCH(MAX(IF(B$1:B$9=E1,A1:A9)),A$1:A$9,0),1)
Array formula, use Ctrl-Shift-Enter

This assumes the dates will not be duplicated
 
Last edited:
Upvote 0
Try the below. It's not an array so just enter is fine

=LOOKUP(2,1/(B:B=K1),C:C)

where B:B is the second column above. K1 is the start of your list of months and C:C contains the values.
 
Upvote 0

Forum statistics

Threads
1,215,459
Messages
6,124,945
Members
449,198
Latest member
MhammadishaqKhan

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