Function: Allow the result of a column to be determined by a the results of a case expression. Author: Arno Brinkman Format: ::= | ::= NULLIF | COALESCE { }... ::= | ::= CASE ... [ ] END ::= CASE ... [ ] END ::= WHEN THEN ::= WHEN THEN ::= ::= ELSE ::= | NULL ::= Syntax Rules: Examples: A) (simple) SELECT o.ID, o.Description, CASE o.Status WHEN 1 THEN 'confirmed' WHEN 2 THEN 'in production' WHEN 3 THEN 'ready' WHEN 4 THEN 'shipped' ELSE 'unknown status ''' || o.Status || '''' END FROM Orders o B) (searched) SELECT o.ID, o.Description, CASE WHEN (o.Status IS NULL) THEN 'new' WHEN (o.Status = 1) THEN 'confirmed' WHEN (o.Status = 3) THEN 'in production' WHEN (o.Status = 4) THEN 'ready' WHEN (o.Status = 5) THEN 'shipped' ELSE 'unknown status ''' || o.Status || '''' END FROM Orders o