CREATE FUNCTION dbo.TRIM(@string VARCHAR(MAX)) RETURNS VARCHAR(MAX) BEGIN RETURN LTRIM(RTRIM(@string)) END GO
SELECT dbo.TRIM(' leading trailing ')
'leading trailing'
No comments:
Post a Comment