Logical Functions

Boolean Operator Functions. Conditionals. Functions Returning Constant Values.
  • AND

    The AND function returns true if all of the provided arguments are logically true, and false if any of the provided arguments are logically false.

    logical_expression1 (mixed)
    An expression or reference to a variable containing an expression that represents some logical value, i.e. TRUE or FALSE, or an expression that can be coerced to a logical value.
    logical_expression2 (mixed)
    Optional: Additional expressions or references to variables containing expressions representing some logical values, i.e. TRUE or FALSE, or expressions that can be coerced to logical values.
  • FALSE

    Returns the logical value `FALSE`.

  • IF

    Returns one value if a logical expression is `TRUE` and another if it is `FALSE`.

    IF(TRUE,4,5)
    Try this example
    logical_expression (mixed)
    An expression or reference to a variable containing an expression that represents some logical value, i.e. TRUE or FALSE.
    value_if_true (any)
    The value the function returns if logical_expression is TRUE.
  • IFNA

    The IFNA function evaluates a value. If the value is an #N/A error, return the specified value.

    IFNA(205, "Na error")
    Try this example
    value (any)
    The value to check if it is a #N/A error.
    value_if_na (any)
    The value to return if the first argument is an #N/A error.
  • IFS

    Evaluates multiple conditions and returns a value that corresponds to the first true condition.

    IFS(TRUE,4,TRUE,5)
    Try this example
    condition1 (mixed)
    The first condition to be evaluated. This can be a boolean, a number, an array, or a reference to any of those.
    value1 (any)
    The returned value if condition1 is TRUE.
  • NOT

    Returns the opposite of a logical value - `NOT(TRUE)` returns `FALSE`; `NOT(FALSE)` returns `TRUE`.

    logical_expression (mixed)
    An expression or reference to a variable holding an expression that represents some logical value, i.e. TRUE or FALSE.
  • OR

    The OR function returns true if any of the provided arguments are logically true, and false if all of the provided arguments are logically false.

    OR(TRUE,FALSE,TRUE)
    Try this example
    logical_expression1 (mixed)
    An expression or reference to a variable containing an expression that represents some logical value, i.e. TRUE or FALSE, or an expression that can be coerced to a logical value.
    logical_expression2 (mixed)
    Optional: Additional expressions or references to variables containing expressions representing some logical values, i.e. TRUE or FALSE, or expressions that can be coerced to logical values.
  • SUMIFS

    Sums items that meet multiple criteria.

    SUMIFS({var1},{var2},1,{var3}, "North" )
    Try this example
    sum_range (array)
    The range to be summed.
    range1 (array)
    The first range to evaulate.
  • SWITCH

    Tests an expression against a list of cases and returns the corresponding value of the first matching case, with an optional default value if nothing else is met.

    SWITCH({var1}, 0, "No", 1, "Other")
    Try this example
    expression (array)
    Any valid values.
    case1 (number)
    The first case to be checked against expression.
  • TRUE

    Returns the logical value `TRUE`.

  • XOR

    The XOR function returns TRUE if an odd number of the provided arguments are logically true, and FALSE otherwise.

    XOR(0, 1, 2, 3)
    Try this example
    logical_expression1 (mixed)
    An expression or reference to a variable containing an expression that represents some logical value, e.g. "TRUE" or "FALSE," or an expression that can be coerced to a logical value.
    logical_expression2 (mixed)
    More expressions or variable references that represent logical values.