explain.depesz.com

PostgreSQL's explain analyze made readable

Result: O75x

Settings
# exclusive inclusive rows x rows loops node
1. 2,217.235 7,979.220 ↓ 50.0 50 1

Nested Loop (cost=10.85..20.77 rows=1 width=226) (actual time=646.095..7,979.220 rows=50 loops=1)

  • Join Filter: ((temp_process_game_player_id.player_id = process_game_player_rating.player_id) AND (temp_process_game_player_id.process_game_player_param_id = process_game_player_rating.process_game_player_param_id) AND (t1.max_id = process_game_player_rating.id))
  • Rows Removed by Join Filter: 9290150
2. 0.303 472.635 ↓ 50.0 50 1

Hash Join (cost=10.41..12.30 rows=1 width=20) (actual time=472.247..472.635 rows=50 loops=1)

  • Hash Cond: ((temp_process_game_player_id.player_id = t1.player_id) AND (temp_process_game_player_id.process_game_player_param_id = t1.process_game_player_param_id))
3. 0.120 0.120 ↑ 1.0 50 1

Seq Scan on temp_process_game_player_id (cost=0.00..1.50 rows=50 width=8) (actual time=0.019..0.120 rows=50 loops=1)

4. 4.045 472.212 ↓ 50.0 50 1

Hash (cost=10.40..10.40 rows=1 width=12) (actual time=472.212..472.212 rows=50 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 11kB
5. 0.009 468.167 ↓ 50.0 50 1

Subquery Scan on t1 (cost=10.36..10.40 rows=1 width=12) (actual time=466.115..468.167 rows=50 loops=1)

6. 1.248 468.158 ↓ 50.0 50 1

GroupAggregate (cost=10.36..10.39 rows=1 width=12) (actual time=466.115..468.158 rows=50 loops=1)

  • Group Key: process_game_player_rating_1.player_id, process_game_player_rating_1.process_game_player_param_id
7. 4.681 466.910 ↓ 9,613.0 9,613 1

Sort (cost=10.36..10.37 rows=1 width=12) (actual time=466.053..466.910 rows=9,613 loops=1)

  • Sort Key: process_game_player_rating_1.player_id, process_game_player_rating_1.process_game_player_param_id
  • Sort Method: quicksort Memory: 835kB
8. 82.821 462.229 ↓ 9,613.0 9,613 1

Hash Join (cost=8.47..10.35 rows=1 width=12) (actual time=379.510..462.229 rows=9,613 loops=1)

  • Hash Cond: ((temp_process_game_player_id_1.player_id = process_game_player_rating_1.player_id) AND (temp_process_game_player_id_1.process_game_player_param_id = process_game_player_rating_1.process_game_player_param_id))
9. 0.013 0.013 ↑ 1.0 50 1

Seq Scan on temp_process_game_player_id temp_process_game_player_id_1 (cost=0.00..1.50 rows=50 width=8) (actual time=0.003..0.013 rows=50 loops=1)

10. 120.538 379.395 ↓ 185,804.0 185,804 1

Hash (cost=8.45..8.45 rows=1 width=12) (actual time=379.395..379.395 rows=185,804 loops=1)

  • Buckets: 131072 (originally 1024) Batches: 4 (originally 1) Memory Usage: 3073kB
11. 258.857 258.857 ↓ 185,804.0 185,804 1

Index Scan using ix_process_game_player_rating_process_id on process_game_player_rating process_game_player_rating_1 (cost=0.43..8.45 rows=1 width=12) (actual time=0.021..258.857 rows=185,804 loops=1)

  • Index Cond: (process_id = 40)
12. 5,289.350 5,289.350 ↓ 185,804.0 185,804 50

Index Scan using ix_process_game_player_rating_process_id on process_game_player_rating (cost=0.43..8.45 rows=1 width=226) (actual time=0.016..105.787 rows=185,804 loops=50)

  • Index Cond: (process_id = 40)