Consider a database table connectouser
holding two IDs:
connectouser
compID coopID
1 1
1 2
1 3
2 1
2 2
Consider another database table coop
holding two IDs:
coop
ID Name
1 ABC
2 DEF
3 GHJ
I want to the following output :
Result
compID coopname
1 ABC,DEF,GHJ
2 ABC,DEF
Can anyone please help me on this.