Skip to content
Advertisement

How to list data from join table in one row?

There 3 entities: 1) Question, 2) Tag and join table between them – question_has_tag.

When I make a select query like:

I’m getting the following result:

and I needed to get:

How to get it ?

Advertisement

Answer

You need to GROUP them and use GROUP_CONCAT

Like

User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement