SELECT *
FROM (
SELECT KNOWLEDGE_OID,
ROW_NUMBER() OVER ( PARTITION BY KNOWLEDGE_OID ORDER BY LATEST_SCORE DESC ) rid
FROM T_REPORT_SCORE
) AS t
WHERE rid = 1
SELECT *
FROM (
SELECT KNOWLEDGE_OID,
ROW_NUMBER() OVER ( PARTITION BY KNOWLEDGE_OID ORDER BY LATEST_SCORE DESC ) rid
FROM T_REPORT_SCORE
) AS t
WHERE rid = 1