IFERROR Function (DAX)

How does the IFERROR function (DAX) work?

IFERROR function (DAX) evaluates an expression and returns a specified value, if the expression returns an error; otherwise returns the value of the expression itself.

IFERROR Formula Syntax

IFERROR(value, value_if_error)

How do you use the IFERROR function?

You can use the IFERROR function to trap and handle errors in an expression.

If value or value_if_error is an empty cell, IFERROR treats it as an empty string value (“”).

Related Blog Posts

Related Support Forum Posts

IF Function needs a calculation
Multi Criteria, IF and contains
Handling Negative Margin Calculation

Considerations when using the IFERROR function

The IFERROR function is based on the IF function, and uses the same error messages, but has fewer arguments. The relationship between the IFERROR function and the IF function as follows:


Note that the values that are returned for A and B must be of the same data type; therefore, the column or expression used for value and the value returned for value_if_error must be the same data type.

Related Video Tutorials

EDNA TV-Unique subtotal
EDNA TV-Harvesting a slicer selection

Formula examples using the IFERROR function


Related DAX Functions

Logical Functions

Related Course Modules



Download our comprehensive DAX Formula Reference Guide as perfect companion as you learn how to use DAX formulas within Power BI.

Download DAX Formulas Reference Guide
Download DAX Formula Reference Guide