chapter 5.3 Flashcards
what are the 2 conditional expressions
case and decode
which conditional expression is similar to case
NULLIF
what kind of statement is case
ANSI/ISO 99 SQL 99 compliant statement
what kind of statement is decode
Oracle proprietary statement
what is the rule for data types in the case, when and else expressions
data types must be the same
syntax for case expression
CASE expr WHEN comparison_expr1 THEN return_expr1
ELSE else_expr
END
what does decode do
compares an expression to each of the search values
what is the syntax for decode
DECODE(column1|expression, search1, result 1
[, default1])
if the default is ommited null value is returned when search value doesnt match any of the value s