BOOLXOR

functionsupportedCore SQL functions

docs.snowflake.com ↗

Conditional expression functions

Computes the Boolean XOR of two numeric expressions; that is, one of the expressions, but not both expressions, is true. In accordance with Boolean semantics: - Non-zero values, including negative numbers, are regarded as true. - Zero values are regarded as false. As a result, the function returns: - True if one expression is non-zero and the other expression is zero. - False if both expressions are non-zero or both expressions are zero. - NULL if one or both expressions are NULL.

Syntax

BOOLXOR( <expr1> , <expr2> )

Parameters

NameRequiredDescription
expr1requiredA numeric expression.
expr2requiredA numeric expression.

Returns

This function returns a value of type BOOLEAN or NULL.

Usage notes

See also

Referenced by