View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Pete_UK Pete_UK is offline
external usenet poster
 
Posts: 8,856
Default 2 Conditions + Sum of a colum matching those conditions

You can use an array* formula like this:

=SUM(IF((C1:C100="Windows desktop")*(O1:O100="HP Finance"),G1:G100,0))

* As this is an array formula, then when you type it in (or
subsequently edit it) you must use CTRL-SHIFT-ENTER to commit it
rather than just ENTER. If you do this correctly then Excel will wrap
curly braces { } around the formula when viewed in the formula bar -
you must not type these yourself.

An alternative (non-array) formula is:

=SUMPRODUCT(--(C1:C100="Windows desktop"),--(O1:O100="HP
Finance"),G1:G100)

In both cases the array ranges should be the same size, but cannot be
a complete column - I've assumed you have 100 of them, so adjust this
to suit your data.

Hope this helps.

Pete

On Jun 7, 5:27 am, Jeffa wrote:
Ok.. I've spent the last 2 hours reading this area trying to find a close
enough match to what I am looking for. I know this will be simple.. but I've
ended up having to post.. I'm sorry :(.

This is what I have..

Col c = windows desktop or windows laptop
Col g = It's monthly $ charge
Col o = Who it is owned by (Finance companies)

I would like to have a breakdown of Desktops laptops with a cost item.. For
example

If col c = "Windows Desktop" & Col o = "HP Finance" Sum(g:g) (what's left
after the 2 conditions are met.

Hope that makes sense.. I'd love some help :)
Regards,

Jeffrey