MySQL Forums
Forum List  »  Newbie

Re: Complex JOIN
Posted by: Peter Brawley
Date: July 11, 2015 08:47AM

>list each user in the first column and skills along the first row

Is this what you mean?

select u.username, x.skillslist
from users u
join (
  select us.userid, group_concat(s.skill) as skillslist
  from userskills us
  join skills s on us.skillsid=s.skillsid
  group by us.userid
) x on u.userid=x.userid;

Options: ReplyQuote


Subject
Written By
Posted
July 11, 2015 01:30AM
Re: Complex JOIN
July 11, 2015 08:47AM
July 12, 2015 02:13AM
July 12, 2015 09:41AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.