Monday, 15 October 2012

SQL Server - Removing New Line characters



If you suspect that your varchar variable has a new line character , use the following to remove it -

REPLACE(REPLACE( @variable,CHAR(13),''),CHAR(10),'')

No comments:

Post a Comment