Write a solution to find all the pairs (actor_id
, director_id
) where the actor has cooperated with the director at least three times.
Return the result table in any order.
The result format is in the following example.
GROUP BY
에 다중 조건을 걸 수 있다.SELECT actor_id, director_id FROM ActorDirector
GROUP BY actor_id, director_id
HAVING COUNT(timestamp) >= 3