Guys, actually this is my question.
There are 3 tables.
cities - the cities
kladr_id - unique key of the city
manager_cities - the town which are assigned by Manager
manager_id - the ID of the user from the table managers
kladr_id - from the cities table
managers - table managers
manager_id - the unique key of the Manager
The point is that one Manager can operate in several cities and I need to get on the page with the list of all the managers, their data. It turns out the table for display shall be:
Name | phone Number | City (ies)
Please help to write a query to select the name, phone number and all the cities assigned to the Manager. Simple JOINS you are not suitable, because I get duplicate data Manager, if it is enshrined in several cities.