SQL Server 6.5 appears to not differentiate between zero length strings and strings containing a single space.
It is true in all versions of SQL Server that Trailing spaces are ignored in =
comparisons but this issue is different.
This SELECT returns 1:
SELECT DATALENGTH('')
I have a table with a varchar(20)
column FAX
upon which this update seems to have no effect:
UPDATE CLIENT
SET FAX = '' -- The existing field consists only of a single space
WHERE ClientNo = 124
The field still contains a blank space even after this update is run.
Trimming a field that consists only of spaces results in a NULL value, which is undesirable for our purposes.
Is it possible to replace blank values with an empty string? How would I go about it?