Navigation:  »No topics above this level«

COALESCE()

Advantage Concepts

Return to chapter overview

Scalar function that returns the first non-NULL expression result in a list of values.

Supported in SQL:

Yes

Supported in Navigational:

Yes

Syntax

COALESCE( <expr1>, ... <exprn> ) à expr

Parameters

<exprn>

An expression or value

Return Value

COALESCE returns the first value of <expr1> ... <exprn> that is non-null.

Remarks

All expressions must be of the same type or be implicitly convertible to the same type. No parameters or BLOBs are allowed as an expression type. If all the expressions evaluate to NULL, COALESCE returns a NULL value.

See Also

IIF()