The Oracle DECODE function can be considered an IF/ELSE variation. It compares the very same expression with other or others. Continue reading “The Oracle DECODE function”
Let’s review Oracle date formatting.
This is useful for functions like TO_DATE, TO_CHAR or alter session to modify nls_date_format. Continue reading “Oracle date format”
Let’s take a look at the Oracle numeric format masks. Continue reading “Oracle numeric format”
The NULLIF function evaluates two expressions in the following way:
- If they are equal, it returns NULL.
- If they are not equal, it returns the first expression.
NVL2 provides a similar functionality as NVL function.
This function evaluates a column or expression in the following way:
- If the result is not NULL, it returns the second parameter that was given to NVL2 function.
- If the result is NULL, it returns the third parameter that was given to NVL2.
The NVL function evaluates a column or an expression this way:
- If it’s not NULL, it returns the evaluated value.
- If it’s NULL, it returns the indicated value in the second parameter of NVL.