View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Mike H Mike H is offline
external usenet poster
 
Posts: 11,501
Default Vlookups (sum of)

Caroline,

There are a couple of ways, here's one

=SUMPRODUCT((A1:A6=1001)*(A1:A6<=1003)*(B1:B6))

Mike

"Caroline" wrote:

Hi

I hope someone can help. I think I've solved this before, but cannot
remember for the life of me how to do it!

I have some data that I want to produce some summary figures from:

E.G
Col A Col B

1000 10
1001 20
1002 30
1003 40
1004 50
1005 60

What I want to do is do a vlookup for say 1001 to 1003 inclusive, giving the
result as the sum of the figures in Col B. In this example, the answer would
be 90. Also, would it be possible to miss numbers out, e.g getting the
results from 1000 and then 1003 to 1005? Hope that makes sense and thanks in
advance for your help.

Caroline