Add new line in a query (MSSQL)

use char(13) + char(10) in sql statement to insert new line.

Insert into <table name> (id,data) VALUES (’1′,’test’ + char(13) + char(10) + ‘line’);

This entry was posted in Technology and tagged . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>