SQL, How to Concatenate results?

With MSSQL you can do something like this:

declare @result varchar(500)
set @result=""
select @result = @result + ModuleValue + ', ' 
from TableX where ModuleId = @ModuleId

Leave a Comment