Overview of Control Flow Functions¶
Name |
Description |
|---|---|
CASE WHEN statement is used to calculate a list of conditions and return one of multiple possible result expressions |
|
IF(expr1,expr2,expr3), when expr1 is TRUE, it returns expr2; otherwise, it returns expr3 |
|
IFNULL(expr1,expr2), when expr1 is not NULL, it returns expr1; otherwise it returns expr2 |
|
NULLIF(expr1,expr2), when expr1 = expr2, returns NULL; otherwise, returns the value of expr1 |