In this article:

All | Text | Date | Number | Aggregate | Filters | Lookups | Period | Queries | Math | System | Financial | Conditional | Common

All | Text | Date | Number | Aggregate | Filters | Lookups | Period | Queries | Math | System | Financial | Conditional | Common

These functions test if the data meets a given condition and enable you specify an action dependent on the outcome of that condition.

Tests a condition and returns the given value of "then" if the condition is TRUE, and returns the given value of "else" if the condition is FALSE.

IF(data, then, else)

Example:

data = "yes"

IF(data = "yes", 10, 20) = 10

If the value is between the given from and to values, then returns the given value of "then", else returns the given value of "else". If then and else are ommitted, it returns the tested value as "then" and an empty value as "else".

IFBETWEEN(data, from, to, then, else)

Example:

data = "2019-02"

IFBETWEEN(data, "2019-02",
"2019-03", "yes", "no) = "yes"

Returns the result of an expression, but if the result is empty, then returns the given value of "then". This enables you to set a default value if a column, field, or expression is empty.

IFBLANK(data, then)

Example:

data = ""

IFBLANK(data, "no") = "no"

Returns the result of an expression, or the given value of "then" if the expression results in an error. This enables you to set a default value if an expression results in an error.

IFERROR(data, then)

Example:

IFERROR(12 / 3, 5) = 4

IFERROR(12 / 0, 5) = 5

Tests multiple conditions and returns the "then" value of the first condition that is TRUE. The number of conditions and values is unlimited. Returns an empty value if no condition is met.

IFS(data, then, data, then)

Example:

data = 12

IFS(data > 10, "more then 10", data =< 10,
"less than 10) = "more then 10"