How Oracle 10g evaluates NULL in boolean expressions
Boolean operations with NULL value in Oracle return UNKNOWN
- not true or false. So you have something like this:
If( not(UNKNOWN and (true)) = if not( UNKNOWN) =if( UNKNOWN )
In this case, IF
will treat UNKNOWN as false.
If i_relaunch
can be null, then you need to use some of NULL handling functions(NVL, NVL2, NULLIF, COALESCE, LNNVL
) to be sure that you have correct result.
See these article for more information:
- Nulls: Nothing to Worry About
- Fundamentals of PL/SQL. Scroll down to -
Handling Null Values in Comparisons and Conditional Statements