SELECT events.id, events.name as event_name, events.date_start, events.date_end, events.country_id, events.description, events.day_1, events.day_2, events.month_1, events.month_2, events.year_1, events.year_2, events.is_present, links.links, images.images, countries.countries, clusters.clusters FROM events
LEFT JOIN (SELECT countries.id, event_to_country.event_id, GROUP_CONCAT(countries.name) as countries FROM countries LEFT JOIN event_to_country ON countries.id = event_to_country.country_id GROUP BY event_to_country.event_id) as countries ON events.id = countries.event_id
LEFT JOIN (SELECT event_id, GROUP_CONCAT(link) as links FROM links GROUP BY event_id) AS links ON events.id = links.event_id
LEFT JOIN (SELECT event_id, GROUP_CONCAT(name) as images FROM images GROUP BY event_id) AS images ON events.id = images.event_id
LEFT JOIN keywords ON events.id = keywords.event_id
LEFT JOIN (SELECT country_id as c_id, GROUP_CONCAT(name) as clusters FROM clusters GROUP BY c_id) AS clusters ON countries.id = c_id
WHERE countries.id = :country_id
ORDER BY events.year_1 ASC
LIMIT 30
WHERE countries.id = :country_id
WHERE event_to_country.country_id = :country_id
Или делать еще один JOIN к таблице event_to_country
SELECT countries.*
FROM (
SELECT countries.id, event_to_country.event_id, GROUP_CONCAT(countries.name) as countries
FROM countries
LEFT JOIN event_to_country ON countries.id = event_to_country.country_id
GROUP BY event_to_country.event_id
) as countries
WHERE countries.id = 2
LIMIT 30
SELECT events.id, events.name as event_name, events.date_start, events.date_end, events.country_id, events.description, events.day_1, events.day_2, events.month_1, events.month_2, events.year_1, events.year_2, events.is_present, links.links, images.images, countries.countries, clusters.clusters FROM events
LEFT JOIN (SELECT countries.id, event_to_country.event_id, GROUP_CONCAT(countries.name) as countries FROM countries LEFT JOIN event_to_country ON countries.id = event_to_country.country_id GROUP BY event_to_country.event_id) as countries ON events.id = countries.event_id
LEFT JOIN event_to_country ON event_to_country.country_id = countries.id
LEFT JOIN (SELECT event_id, GROUP_CONCAT(link) as links FROM links GROUP BY event_id) AS links ON events.id = links.event_id
LEFT JOIN (SELECT event_id, GROUP_CONCAT(name) as images FROM images GROUP BY event_id) AS images ON events.id = images.event_id
LEFT JOIN keywords ON events.id = keywords.event_id
LEFT JOIN (SELECT country_id as c_id, GROUP_CONCAT(name) as clusters FROM clusters GROUP BY c_id) AS clusters ON countries.id = c_id
WHERE countries.id = 2
ORDER BY events.year_1 ASC
LIMIT 30
SELECT
events.id, events.name as event_name, events.date_start, events.date_end, events.country_id, events.description, events.day_1, events.day_2, events.month_1,
events.month_2, events.year_1, events.year_2, events.is_present, links.links, images.images, countries.countries, clusters.clusters
FROM events
LEFT JOIN event_to_country etc ON etc.event_id = events.id
LEFT JOIN (
SELECT countries.id, event_to_country.event_id, GROUP_CONCAT(countries.name) as countries
FROM countries
LEFT JOIN event_to_country ON countries.id = event_to_country.country_id
GROUP BY event_to_country.event_id
) as countries ON events.id = countries.event_id
LEFT JOIN (
SELECT event_id, GROUP_CONCAT(link) as links
FROM links
GROUP BY event_id
) AS links ON events.id = links.event_id
LEFT JOIN (
SELECT event_id, GROUP_CONCAT(name) as images
FROM images
GROUP BY event_id
) AS images ON events.id = images.event_id
LEFT JOIN keywords ON events.id = keywords.event_id
LEFT JOIN (
SELECT country_id as c_id, GROUP_CONCAT(name) as clusters
FROM clusters
GROUP BY c_id
) AS clusters ON countries.id = c_id
WHERE
etc.country_id = :country_id
ORDER BY events.year_1 ASC
LIMIT 30
WHERE etc.country_id = 2 AND etc.country_id = 3
SELECT
events.id, events.name as event_name, events.date_start, events.date_end, events.country_id, events.description, events.day_1, events.day_2, events.month_1,
events.month_2, events.year_1, events.year_2, events.is_present, links.links, images.images, countries.countries, clusters.clusters
FROM events
LEFT JOIN event_to_country etc ON etc.event_id = events.id
LEFT JOIN (
SELECT countries.id, event_to_country.event_id, GROUP_CONCAT(countries.name) as countries
FROM countries
LEFT JOIN event_to_country ON countries.id = event_to_country.country_id
GROUP BY event_to_country.event_id
) as countries ON events.id = countries.event_id
LEFT JOIN (
SELECT event_id, GROUP_CONCAT(link) as links
FROM links
GROUP BY event_id
) AS links ON events.id = links.event_id
LEFT JOIN (
SELECT event_id, GROUP_CONCAT(name) as images
FROM images
GROUP BY event_id
) AS images ON events.id = images.event_id
LEFT JOIN keywords ON events.id = keywords.event_id
LEFT JOIN (
SELECT country_id as c_id, GROUP_CONCAT(name) as clusters
FROM clusters
GROUP BY c_id
) AS clusters ON countries.id = c_id
WHERE etc.country_id = 2 AND etc.country_id = 8
ORDER BY events.year_1 ASC
LIMIT 30
SELECT
events.id, events.name as event_name, events.date_start, events.date_end, events.country_id, events.description, events.day_1, events.day_2, events.month_1,
events.month_2, events.year_1, events.year_2, events.is_present, links.links, images.images, countries.countries, clusters.clusters
FROM events
LEFT JOIN event_to_country etc ON etc.event_id = events.id
LEFT JOIN event_to_country etc2 ON etc2.event_id = events.id
LEFT JOIN (
SELECT countries.id, event_to_country.event_id, GROUP_CONCAT(countries.name) as countries
FROM countries
LEFT JOIN event_to_country ON countries.id = event_to_country.country_id
GROUP BY event_to_country.event_id
) as countries ON events.id = countries.event_id
LEFT JOIN (
SELECT event_id, GROUP_CONCAT(link) as links
FROM links
GROUP BY event_id
) AS links ON events.id = links.event_id
LEFT JOIN (
SELECT event_id, GROUP_CONCAT(name) as images
FROM images
GROUP BY event_id
) AS images ON events.id = images.event_id
LEFT JOIN keywords ON events.id = keywords.event_id
LEFT JOIN (
SELECT country_id as c_id, GROUP_CONCAT(name) as clusters
FROM clusters
GROUP BY c_id
) AS clusters ON countries.id = c_id
WHERE etc.country_id = 2
AND etc2.country_id = 8
ORDER BY events.year_1 ASC
LIMIT 30
если я условие не передаю в виде стран