Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 SQL SERVER new line character

Author  Topic 

khan46
Starting Member

1 Post

Posted - 2012-07-06 : 04:15:44
HI,

I am getting records from database(sql server)as comma separated.I am getting contact
titles as

greg w.workcerf,ashir ali,asdddfgjk

This comma separater has been defined in sql function getCommaListTitle

What i want is to get these record on new lines as

greg w.workcerf,
ashir ali,
asdddfgjk

Any idea about what should i use in sql function instead of ','

aftabkhan

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2012-07-06 : 04:32:26
CHAR(10) is linefeed
CHAR(13) is carriage return



No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2012-07-06 : 09:28:40
please note that you will be able to see new line only when result is viewed in text in SSMS.

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
   

- Advertisement -