php - Mysql parent record have multiple records in child table show in one column -


i have 2 table

  1. user (user_name,user_id)
  2. servies (service_id, service_name, user_id)

one each user have manay servics e.g
user "john" have many record in servies php, html, seo

i want show each user services follow

user_name ---------------servies   john --------------------php, html,seo   miky --------------------java, c# , objective c   

i want select query of results

select user_name,group_concat(service_name) user  join servies on user.user_id=servies.user_id group user_name 

Comments

Popular posts from this blog

c# - How to get the current UAC mode -

postgresql - Lazarus + Postgres: incomplete startup packet -

javascript - Ajax jqXHR.status==0 fix error -