SQL — IFF() Function

Syntax

IFF (num_expr,true_str,false_str)

Description

The IFF() function tests a specified numeric expression and returns one of two strings, based on whether the expression tested was true or false.

Example

Select IFF(curr_bal>0,'Yes','No'), last_name from customer