SELECT STUFF((SELECT ',' + cast(ID as varchar) AS [text()] FROM tbl_records FOR XML PATH('') ), 1, 1, '' )
PIVOT
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)