1

I am putting new lines as CHAR(13)+CHAR(10). But when copying the text from a table to text editor, new lines (line breaks) are ignored, and formatting is broken.

I want line breaks be preserved when copying from SSMS.

Jakub P
  • 542
  • 4
  • 21
  • Possible duplicate of [How to insert a line break in a SQL Server VARCHAR/NVARCHAR string](https://stackoverflow.com/questions/31057/how-to-insert-a-line-break-in-a-sql-server-varchar-nvarchar-string) – Fourat Apr 25 '18 at 07:34
  • 4
    There's an option in SSMS to remove / keep new lines when copying https://blog.sqlauthority.com/2016/06/03/sql-server-maintain-carriage-return-enter-key-ssms-2016-copy-paste/ – James Z Apr 25 '18 at 07:37
  • 1
    This is not a duplicate. I now how to insert, as I wrote. I want to copy the value from SSMS editor WITH line breaks. – Jakub P Apr 25 '18 at 07:38
  • 1
    Which text editor are you copying the text to so I can replicate your issue? – Mike Poole Apr 25 '18 at 07:38
  • @jamesZ You made it!! – Jakub P Apr 25 '18 at 07:41

0 Answers0