SUMIF(range,criteria,actual_range)
range: cell area
criteria: condition for a cell to be summed
actual_range: cell area, defaults to range
If the actual_range has a size that differs from the size of range, actual_range is resized (retaining the top-left corner) to match the size of range.
This function is Excel compatible.