I have a table location, which contains the values A1, A2, A3... etc in the id column. I have another table location_color like this:
A1   blue
A1   red
A1   green
A2   yellow
A2   red
A3   blue
A3   red
.
.
Now I want to query so the result would be like this
blue,red,green
yellow,red
Blue, red
My query is
select location_color.color
from location_color
where location.id = location_color.location_id
but it's not working.
 
     
    