Wie wäre es mit
SELECT *
FROM (SELECT *,
ROW_NUMBER() OVER(PARTITION BY report_id ORDER BY (SELECT 0)) AS RN
FROM top_keywords
WHERE ym BETWEEN '2010-05' AND '2010-05') TK
WHERE RN <= 10
Wie wäre es mit
SELECT *
FROM (SELECT *,
ROW_NUMBER() OVER(PARTITION BY report_id ORDER BY (SELECT 0)) AS RN
FROM top_keywords
WHERE ym BETWEEN '2010-05' AND '2010-05') TK
WHERE RN <= 10