Multiple choice technology databases

select decode('a','b','value-b','d','value-d','a','value-a','NA') result from dual;

  1. NA

  2. value-d

  3. value-b

  4. value-a

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

DECODE compares expression to search values in order: 'a' matches the third search value 'a', so it returns 'value-a'. If no match occurred, it would return the default 'NA'.