Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: help!! problem in update, replace null with empty string ''
Frank,
Oracle does not distinguish between Empty strings and NULL, like others languages such as Foxpro, where NULL string and empty string are different.
Two quotes together is the symbol for 'literal quote'. Thus, x := '' is not valid, and x := ''' is not legal, and x := '''' is saying assign a string with a literal quote to x.
Selecting LENGTH on the null string will also return NULL. If you wish to test for length=0 then you will need something like:
select nvl(lengthb(x),0) from xxx;
Returns a 0 on the null string.
I did have a circumstance once where the
program was not written to distinguish
two different "kinds" of empty for an edit
box: 1) where no record exists for the row
and 2) where the record exists but the text
is empty..... but this was a design issue
in the code and not a problem with Oracle...
Robert Proffitt
Beckman Coulter
Sent via Deja.com http://www.deja.com/
Before you buy.
Received on Tue Dec 14 1999 - 10:49:32 CST
![]() |
![]() |