przeglądanie Twoich zmian
w takim przypadku spróbuj użyć EXISTS
SELECT c.id
FROM clients AS c
WHERE EXISTS (SELECT * FROM client_project AS cp
WHERE cp.client_id = c.id and cp.project_id = 1)
AND c.active_flag = 1
przeglądanie Twoich zmian
w takim przypadku spróbuj użyć EXISTS
SELECT c.id
FROM clients AS c
WHERE EXISTS (SELECT * FROM client_project AS cp
WHERE cp.client_id = c.id and cp.project_id = 1)
AND c.active_flag = 1