I have a spreadsheet where I need to total values using a SUMIF
function and record that total in another column, but I only want it to record that total for the last instance of a value in the column.
For example, the 11,629
is only shown for the last instance of 103
, etc.
ItemKey | Amount | Subtotal |
---|---|---|
100 | 1,213 | |
103 | 951 | |
103 | 10,656 | |
121 | 435 | |
100 | 6,214 | |
103 | 22 | 11,629 |
121 | 9,753 | |
100 | 343 | 7,770 |
121 | 2,805 | |
121 | 497 | 13,490 |
I have a SUMIF function that works but populates all rows. I need to be able to record the formula in every row, but only have it display something for the last instance.
I guess I need something like an IF(<some way to determine last instance>=True, SUMIF(abcde), "")
, I just don't know how to determine the last instance. What can I do to put this in place?
Maybe a COUNTIF
to count instances from current row to the bottom?