Possible Duplicate:
Simulating group_concat MySQL function in MS SQL Server 2005?
Concat field value to string in SQL Server
There are 2 tables involved, Users and Keywords.
Users
userId
firstName
lastName
...
Keywords
userId
keyword
If I run this query:
select u.userId, u.firstName, u.lastName, k.keyword
from Users as u
inner join Keywords as k on u.userId = k.userId
I get something like this:
What I want is this:
This looked very similar to what I wanted but I can't seem to get it to work right.