How to get column values with comma seperated in sql server

DECLARE @ResultVar VARCHAR(1000)
SELECT @ResultVar = COALESCE(@ResultVar + ', ', '') + CAST(TickerSymbol AS varchar(50))
FROM  company

print @ResultVar

Comments

Popular posts from this blog

List of special Characters in HTML

How to Read TOC Headings from word document using C#