create function removeNewLineChars(@source varchar(150))
returns varchar(150)
as
begin
return replace(replace(replace(@source, char(10), ' '), char(13), ' '), char(9), ' ')
end
As the source and target database are Microsoft SQL Server, T-SQL is the dialect of choice.
Let me say it again: presentation details do not belong in data, at least not in an enterprise system. Unluckily, you see it a lot in old applications (and, alas, even in some new ones). You can shoot me for that, but I won't change my mind.
No comments:
Post a Comment