How to save and Print new line character using SQL server 2008
I am trying to save data to the database with Multiline textbox.
and another process is to read from th开发者_如何学Goe database and prints to a text file.
My problem is:
1) when I am trying to save the data in the database as new line character its taking unusally number of spaces between two words.
Please can any body help me out how to insert new line character in to the database.
thanks
Char(13) is a carriage return and Char(10) is a line feed.
so...
UPDATE tblEXAMPLE
SET Contents=@FIRSTLINE + chAr(13) + chAr(10)
+ @secondline + chAr(10) + chAr(13)
+ @lastline
WHERE KEY=@PRIMARYKEy
精彩评论