Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

how to combine rows in sql server procedure

select id, a.name + coalesce('/'+b.name, '') + coalesce('/'+c.name, '')
from myTable a
left outer join myTable b on a.id=b.id and b.seqno = 2
left outer join myTable c on a.id=c.id and c.seqno = 3
where a.seqno = 1;
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #combine #rows #sql #server #procedure
ADD COMMENT
Topic
Name
6+8 =