Function Problems

How to Use COUNTIF, SUMIFS, and MINIFS Correctly in Excel

Steve KSteve K Nov 10, 2026 868 views

Question details

The user needs to correctly apply COUNTIF, SUMIF/SUMIFS, or MINIFS to calculate usage based on whether data represents remaining levels or usage amounts.

How to Use COUNTIF, SUMIFS, and MINIFS Correctly in Excel
Product
Excel
Device & OS
not provided
Scenario
Calculating total consumption or remaining inventory levels from a dataset containing specific criteria.
Observed behavior
The user attempted to calculate total usage using COUNTIF, which resulted in a count of reading entries rather than the actual sum or difference of the inventory levels.
Before you start

Determine whether your data column contains the actual usage amounts or the remaining inventory levels, as this dictates whether you must use SUMIFS or MINIFS.

Solution 1Recommended

Calculate Usage from Remaining Levels Using MINIFS

Use this method when your dataset logs the remaining amounts in an inventory, and you need to find the total consumed from a known starting capacity.

When readings decline from a starting value (e.g., 150) to zero, you calculate consumption by finding the lowest remaining level and subtracting it from the starting capacity.

1
Identify starting capacity

Determine the maximum or starting capacity of your inventory or tank (e.g., 150).

2
Enter the MINIFS formula

Select the cell for your result and type the formula: =150-MINIFS(H3:H20, B3:B20, "N. Well").

3
Verify results

Press Enter. The formula will find the lowest recorded remaining level for "N. Well" in column H and subtract it from 150 to calculate the total usage.

Matching Ranges: Ensure that your criteria range (B3:B20) and your min_range (H3:H20) are exactly the same size, and that text criteria are enclosed in quotation marks.
Advanced Data Analysis

Master Complex Formulas Easily with WPS Spreadsheet

WPS Spreadsheet fully supports advanced logical and math functions like COUNTIFS, SUMIFS, and MINIFS. It provides an intuitive formula builder and seamless compatibility with Microsoft Excel workbooks, making data analysis straightforward and error-free.

  1. 1. Open data in WPS Spreadsheet: Launch WPS Office and open your dataset containing the inventory or usage logs.
  2. 2. Access the Formula tab: Navigate to the 'Formulas' tab on the ribbon and click on 'Insert Function'.
  3. 3. Input arguments visually: Search for SUMIFS or MINIFS, and use the dialog box to select your sum range and criteria ranges without worrying about syntax errors.
Fully compatible with Microsoft Excel formulas including SUMIFS, COUNTIFS, and MINIFS.Built-in function arguments dialog to help properly format complex calculations.Free, lightweight, and user-friendly interface for powerful data analysis.
microsoft office alternative - wps office

Frequently Asked Questions

Why does COUNTIF return a small number instead of my total usage?

COUNTIF only counts the number of cells that meet your criteria (e.g., how many times a reading was logged). It does not sum the numerical values inside those cells. You must use SUMIF or SUMIFS to add values together.

What is the difference between SUMIF and SUMIFS?

SUMIF evaluates a single condition, while SUMIFS can evaluate multiple conditions across different ranges. Additionally, the syntax order differs: SUMIFS requires the sum range first, whereas SUMIF places the sum range last.

Why is my MINIFS formula returning an error?

Common causes for MINIFS errors include mismatched range sizes (e.g., the criteria range is B3:B20 but the min_range is H3:H21) or forgetting to enclose text criteria in quotation marks. Ensure all ranges align perfectly and criteria are properly formatted.