It was returning the correct scores for the user_id's but the id's weren't related anymore.
Code:
SELECT MAX(total_score) AS max_score, user_id, MAX(id) AS id FROM "rounds" GROUP BY user_id ORDER BY max_score DESC LIMIT 10;
max_score | user_id | id
-----------+---------+----
131.16 | 1 | 55
55 | 44 | 54
49.2 | 30 | 28
42.33 | 33 | 49
32.7 | 7 | 10
32 | 34 | 35
19.135 | 40 | 44
18.5 | 38 | 48
17.3 | 41 | 46
13.04 | 3 | 4
(10 rows)
Code:
SELECT total_score from rounds WHERE id IN (55,54,28,49,10,35,44,48,46,4) ORDER BY total_score DESC;
total_score
-------------
19.135
0
0
0
0
0
0
0
0
0
Bookmarks