View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Sean Timmons Sean Timmons is offline
external usenet poster
 
Posts: 1,696
Default sum based on 2 criteria within a table

That would be SUMPRODUCT()

=SUMPRODUCT(--(A2:A1000="Bob"),--(B2:B1000=12345678),C2:C1000)

Couple of notes:

All three data sets must encompass the same number of rows.

You should not reference, say, A:A. SUMPRODUCT is not a fan of entire column
or row searches.

Of course, I hard coded names, but you'll probably want to enter, dsay, D2
instead of "Bob" and E2 instead of the account #.

"herkimer" wrote:

I am trying to do a SUMIF on a table, but I have multiple criteria in 2
columns.

The table is such that the name repeats several times, as there is another
column with account numbers in it, which in most cases also has multiple
lines. The last column holds dollar amounts.

I want to sum the dollar amounts for a specified name/account number
combination from the table. SUMIF appears to only work for one variable.

What function can I use to do this?

Thx
--
herkimer