View Single Post
 
Old 01-12-2015, 05:10 PM
gebobs gebobs is offline Windows 7 64bit Office 2010 64bit
Expert
 
Join Date: Mar 2014
Location: Atlanta
Posts: 837
gebobs has a spectacular aura aboutgebobs has a spectacular aura about
Default

What sumproduct does is give a sum of all the products of values in one range multiplied with those in another (or more even). For your example, it is effectively summing (0*194), (0*286), and (1*52).

Sumproduct is great at extracting data from a table based on multiple criteria. Say you have a table with EntryDate, Customer, Type, Amount and you want all the total amount of the records for 1/5/14 for XYZ Inc. that are credits:

=sumproduct(EntryDate=Datevalue("1/5/14")*(Customer="XYZ Corp.)*(Type="C"),(Amount))

Your equation will work if written as:

=SUMIF(b2:b4,">0", c2:c4)

The criteria has to be a string.
Reply With Quote