Skip to content
Free Excel Tutorials
  • Home
  • Excel For Beginners
  • Excel Intermediate
  • Advanced Excel For Experts

Data Analysis

  • How To Sort One Column or Multiple Columns in Excel
  • Conditional Formatting Icon Sets Examples in Excel
  • How to calculate average last N values in a table in Excel
  • Get column index in Excel Table
  • How to calculate correlation coefficient Correlation in Excel

References

  • How to get address of first cell in range in Excel
  • CHOOSE function: Description, Usage, Syntax, Examples and Explanation
  • LOOKUP function: Description, Usage, Syntax, Examples and Explanation
  • How to calculate two-way lookup VLOOKUP in Excel Table
  • Left Lookup in Excel

Data Validations

  • Excel Data validation no punctuation
  • Excel Data validation must contain specific text
  • Excel Data validation date in next 30 days
  • Excel Data validation allow weekday only
  • Excel Data validation require unique number

SUMPRODUCT count multiple OR criteria in Excel

by

This tutorial shows how to work SUMPRODUCT count multiple OR criteria in Excel using the example below;

Formula

=SUMPRODUCT(ISNUMBER(MATCH(range1,{"A","B"},0))*ISNUMBER(MATCH(range2,{"X","Y","Z"},0)))

Explanation

To count matching rows with multiple OR criteria, you can use a formula based on the SUMPRODUCT function. In the example shown, the formula in F10 is:

=SUMPRODUCT(ISNUMBER(MATCH(B5:B11,{"A","B"},0))*
ISNUMBER(MATCH(C5:C11,{"X","Y","Z"},0)))

This formula returns a count of rows where column one is A or B and column two is X, Y, or Z.

How this formula works

Working from the inside out, each criteria is applied with a separate ISNUMBER + MATCH construction. To generate a count of rows in column one where the value is A or B we use:

ISNUMBER(MATCH(B5:B11,{"A","B"},0)

MATCH generates a result array that looks like this:

{1;2;#N/A;1;2;1;2}

and ISNUMBER converts this array to this array:

{TRUE;TRUE;FALSE;TRUE;TRUE;TRUE;TRUE}

To generate a count of rows in column two where the value is X, Y, or Z we use:

ISNUMBER(MATCH(C5:C11,{"X","Y","Z"},0))

Then MATCH returns:

{1;2;3;3;#N/A;1;2}

and ISNUMBER converts to:

{TRUE;TRUE;TRUE;TRUE;FALSE;TRUE;TRUE}

These two arrays are multiplied together inside SUMPRODUCT, which automatically converts TRUE FALSE values to 1 and 0 as part of the math operation.

So, to visualize, the final result is derived like this:

=SUMPRODUCT({1;1;0;1;1;1;1}*{1;1;1;1;0;1;1})
=SUMPRODUCT({1;1;0;1;0;1;1})
=5

With cell references

The example above uses hardcoded array constants, but you can also use cell references:

=SUMPRODUCT(ISNUMBER(MATCH(B5:B11,E5:E6,0))*ISNUMBER(MATCH(C5:C11,F5:F7,0)))

Post navigation

Previous Post:

How to use Excel CHOOSE Function

Next Post:

Customize Ribbon In Excel

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Learn Basic Excel

Ribbon
Workbook
Worksheets
Format Cells
Find & Select
Sort & Filter
Templates
Print
Share
Protect
Keyboard Shortcuts

Categories

  • Charts
  • Data Analysis
  • Data Validation
  • Excel Functions
    • Cube Functions
    • Database Functions
    • Date and Time Functions
    • Engineering Functions
    • Financial Functions
    • Information Functions
    • Logical Functions
    • Lookup and Reference Functions
    • Math and Trig Functions
    • Statistical Functions
    • Text Functions
    • Web Functions
  • Excel VBA
  • Excel Video Tutorials
  • Formatting
  • Grouping
  • Others

Logical Functions

  • IF with boolean logic in Excel
  • SWITCH function: Description, Usage, Syntax, Examples and Explanation
  • TRUE function: Description, Usage, Syntax, Examples and Explanation
  • Return blank if in Excel
  • OR function Examples in Excel

Date Time

  • Sum through n months in Excel
  • Calculate series of dates by workdays in Excel
  • TIMEVALUE function: Description, Usage, Syntax, Examples and Explanation
  • Add years to date in Excel
  • WORKDAY.INTL function: Description, Usage, Syntax, Examples and Explanation

Grouping

  • How to randomly assign data to groups in Excel
  • How to randomly assign people to groups in Excel
  • Map text to numbers in Excel
  • Map inputs to arbitrary values in Excel
  • Group times into unequal buckets in Excel

General

  • Automatically fill series of cells in Excel using AutoFill
  • Subtotal invoices by age in Excel
  • Find Most Frequently Occurring Word in Excel Worksheet
  • How to make excel worksheets print on one page?
  • List worksheet index numbers in Excel
© 2026 xlsoffice . All Right Reserved. | Teal Smiles | Abbreviations And Their Meaning