Excel Function
SUMIF
Sums values that meet a condition.
SUMIF(range, criteria, [sum_range])Arguments
range
RequiredSpecify the range used for condition check or aggregation.
criteria
RequiredEnter the match condition, e.g. "Food", ">=80", "<>0".
sum_range
OptionalSpecify the range of values to sum.
Practice Preview
sum sales that match a condition. Use SUMIF to Sums values that meet a condition. For range arguments, drag from the start cell to the end cell in the same argument field, or click start and end cells in order. For criteria, enter a match condition such as "text condition", ">=number", or "<>blank". use "食品" for criteria. Fill the argument fields below and complete a formula that achieves this goal.
Sample correct formula
=SUMIF(C2:C8, "食品", D2:D8)