Hi,
I have the following table:
I need to combine all of the 'names' information into one single row grouped by the irecordid. I need to end up with:
Irecordid Names
1 SMITH JOHNSON ANDERSON JENKINS
2 MATTHEWS MORRIS RICHFIELD CHATFIELD HENRY
I have played around with several comborsome methods and thought I would see what ideas people had to do this?
Thanks!
Brian
I have the following table:
Code:
create table #temp (irecordid int, names varchar(50))
go
insert into #temp values (1, 'SMITH')
insert into #temp values (1, 'JOHNSON')
insert into #temp values (1, 'ANDERSON')
insert into #temp values (1, 'JENKINS')
insert into #temp values (2, 'MATTHEWS')
insert into #temp values (2, 'MORRIS')
insert into #temp values (2, 'RICHFIELD')
insert into #temp values (2, 'CHATFIELD')
insert into #temp values (2, 'HENRY')
I need to combine all of the 'names' information into one single row grouped by the irecordid. I need to end up with:
Irecordid Names
1 SMITH JOHNSON ANDERSON JENKINS
2 MATTHEWS MORRIS RICHFIELD CHATFIELD HENRY
I have played around with several comborsome methods and thought I would see what ideas people had to do this?
Thanks!
Brian