I asked some people that should know (including a former DBA) and everyone told me that "" != null - always.
Digging around I found the following in an Oracle manual:
Note: Oracle Database currently treats a character value with a length of zero as null. However, this may not continue to be true in future releases, and Oracle recommends that you do not treat empty strings the same as nulls.
So in this case "" == null.
It is ok if one knows it and one can work around, but it came as surprise to me and others.
No comments:
Post a Comment