In PL/SQL V1, the LENGTH function applied to a null expression resolves to zero. In versions after V1, the LENGTH function applied to a null expression resolves to null.
To preserve V1 behavior, the PL/SQL conversion utility adds the NVL SQL predicate to ensure that the LENGTH function applied to a null expression resolves to zero.
The conversion utility converts this PL/SQL V1 code:
c:=null;
l=LENGTH( c ); In V1, this resolves to 0
c:=null;
l=NVL(LENGTH( c ),0); Converter wraps LENGTH function
with NVL( ) Built-in, forcing the
expression to resolve to 0