Whoops, add the 32 game req.
authorAnt Zucaro <azucaro@gmail.com>
Sun, 22 Jan 2012 17:36:21 +0000 (12:36 -0500)
committerAnt Zucaro <azucaro@gmail.com>
Sun, 22 Jan 2012 17:36:21 +0000 (12:36 -0500)
scripts/update_ranks.sql

index 0b50125..2fcd64c 100644 (file)
@@ -11,6 +11,7 @@ begin;
     select p.player_id, p.nick, pe.game_type_cd, pe.elo, rank() 
     over (partition by pe.game_type_cd order by pe.elo desc)
     from players p, player_elos pe
-    where p.player_id = pe.player_id;
+    where p.player_id = pe.player_id
+    and pe.games > 32;
 
 end;