In Oracle/PLSQL, the mod function returns the remainder of m divided by n.
like Mod(m,n) , e..g mod(2,3) =2.
the trick is, if some of the variable value is null ,the mod(m,n) will give null as the result.
Let's say m is: 65536+variableA , and if m is null, we just return a null as the result.
We don't need to do like : NVL2( m, mod(m,n), null), just use mod(m,n) as well, it will give the same result
like Mod(m,n) , e..g mod(2,3) =2.
the trick is, if some of the variable value is null ,the mod(m,n) will give null as the result.
Let's say m is: 65536+variableA , and if m is null, we just return a null as the result.
We don't need to do like : NVL2( m, mod(m,n), null), just use mod(m,n) as well, it will give the same result
Comments
Post a Comment