how to find out name with leading and trailing spaces in sql code example
Example: sql find leading space
SELECT ID, Data, FieldName
FROM table
WHERE DATALENGTH(RTRIM(LTRIM(Data))) <> DATALENGTH(Data)
SELECT ID, Data, FieldName
FROM table
WHERE DATALENGTH(RTRIM(LTRIM(Data))) <> DATALENGTH(Data)