# Excel question (summing range)

**URL:** <https://boards.straightdope.com/t/excel-question-summing-range/415557>\
**Category:** Factual Questions\
**Created:** [August 14, 2007, 3:17pm UTC](https://boards.straightdope.com/t/excel-question-summing-range/415557 "2007-08-14T15:17:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Cagey\_Drifter](https://avatars.discourse-cdn.com/v4/letter/c/b2d939/32.png) [@Cagey\_Drifter](https://boards.straightdope.com/u/Cagey_Drifter)\
**Post date:** [August 14, 2007, 3:17pm UTC](https://boards.straightdope.com/t/excel-question-summing-range/415557/1 "2007-08-14T15:17:00Z")

</div>

Here’s the deal. I have a list of dates (column A) and dollar amounts (column B). On another sheet, I am wanting to use a vlookup to find a date in column A on the first sheet, and add up the corresponding dollar amount in column B, as well as the next 4 dollar amounts after that (i.e. the dollar amounts of the subsequent 4 dates). How do I do it?

---

<div class="post-metadata">

**Author:** ![SCSimmons](https://avatars.discourse-cdn.com/v4/letter/s/e495f1/32.png) [@SCSimmons](https://boards.straightdope.com/u/SCSimmons)\
**Post date:** [August 14, 2007, 6:24pm UTC](https://boards.straightdope.com/t/excel-question-summing-range/415557/2 "2007-08-14T18:24:16Z")

</div>

[QUOTE=Cagey Drifter]  
Here’s the deal. I have a list of dates (column A) and dollar amounts (column B). On another sheet, I am wanting to use a vlookup to find a date in column A on the first sheet, and add up the corresponding dollar amount in column B, as well as the next 4 dollar amounts after that (i.e. the dollar amounts of the subsequent 4 dates). How do I do it?  
[/QUOTE]

This worked for me:

=SUM(INDIRECT(“B” & MATCH(D2,A2:A9,FALSE)+1 & “:B” & MATCH(D2,A2:A9,FALSE)+5))

This is with headers in row 1 and data starting in row 2.

How it works is left as an exercise for the student … 😉
