SQL NULLIF Function

Example

Compare two expressions:

SELECT NULLIF(25, 25);

Definition and Usage

The NULLIF() function returns NULL if two expressions are equal, otherwise it returns the first expression.

Syntax

NULLIF(expr1, expr2)

Continue reading SQL NULLIF Function