Understanding and Using the SUMIF Function in Microsoft Excel


The SUMIF function in Microsoft Excel is a conditional summing function that adds up the values in a specified range based on specified criteria. The syntax for the SUMIF function is as follows:

SYNTAX

SUMIF(range, criteria, [sum_range]).

  • Range is the range of cells you want to apply the criteria to.
  • Criteria is the value or expression that determines which cells in the range will be added up.
  • Sum_range (optional) is the range of cells you want to add up. If the sum_range is not specified, the range argument is used as the sum_range.

Example

S.NoYearProductSales
12021PEN5896
22020 PENCIL 7542
32020 PEN 1200
42021 PENCIL 2500
52021 NOTE6500
62020 NOTE6500

The formula should look something like this :

=SUMIF(K21:K26,P23,N21:N26)

Output



To find the total sales amount based on year using the SUMIF function in Microsoft Excel, you can use the following steps:

  • Arrange your data in columns, with the sales figures in one column and the corresponding dates (including year) in another column.
  • In a new column, create a formula using the SUMIF function. The formula should look where K21: K26 is the range of dates, "2021" is the criteria (the year you want to find the total sales for), and N21:N26 is the range of sales figures.
  • Copy the formula down to the rest of the cells in the column to find the total sales for each year.
  • Adjust the formula as needed, changing the ranges and criteria to match your data.For example, if the sales figures are in column A and the corresponding dates are in column B, the formula to find the total sales for the year 2021 would be =SUMIF(K21:K26, "2021", N21:N26),. The SUMIF function will add up the values in column N that correspond to the dates in column K that match the criteria "2021". The result of the calculation will be the total sales for the year 2021.

By using the SUMIF function in this way, you can easily find the total sales for each year and analyze your sales data based on the year, allowing you to make informed decisions about your business and sales strategies.

The SUMIF function is useful for performing conditional summing, allowing you to analyze and summarize data based on specified criteria, making it a valuable tool for data analysis and management in Microsoft Excel.