Home Forums Article Discussions Article Discussions by Author Discuss content posted by Luis Costa get all values separated by commas RE: get all values separated by commas
brian.healy
SSC-Addicted
Points: 451
More actions
July 19, 2012 at 1:37 am
#1514647
Neat use of update. This can also be done using the FOR XML construct:
select SUBSTRING((SELECT (',' + id) FROM teste ORDER BY id FOR XML PATH('') ), 2, 1000)