explain.depesz.com

PostgreSQL's explain analyze made readable

Result: p3w5

Settings
# exclusive inclusive rows x rows loops node
1. 0.256 2.977 ↓ 1.2 124 1

Sort (cost=265.64..265.89 rows=100 width=890) (actual time=2.969..2.977 rows=124 loops=1)

  • Sort Key: t.name
  • Sort Method: quicksort Memory: 176kB
2. 0.098 2.721 ↓ 1.2 124 1

Hash Semi Join (cost=58.86..262.32 rows=100 width=890) (actual time=0.817..2.721 rows=124 loops=1)

  • Hash Cond: (p.team_id = "ANY_subquery".team_ids)
3. 0.192 2.380 ↓ 5.9 586 1

Hash Join (cost=15.38..217.47 rows=100 width=894) (actual time=0.510..2.380 rows=586 loops=1)

  • Hash Cond: (p.team_id = t.id)
4. 0.268 2.164 ↓ 5.9 586 1

Nested Loop (cost=12.93..214.70 rows=100 width=883) (actual time=0.470..2.164 rows=586 loops=1)

5. 0.198 0.718 ↓ 5.9 589 1

Hash Semi Join (cost=12.66..27.21 rows=100 width=12) (actual time=0.459..0.718 rows=589 loops=1)

  • Hash Cond: (c.id = (((jsonb_object_keys(users.cards)))::integer))
6. 0.083 0.083 ↑ 1.0 589 1

Seq Scan on cards c (cost=0.00..11.89 rows=589 width=12) (actual time=0.007..0.083 rows=589 loops=1)

7. 0.105 0.437 ↓ 5.9 589 1

Hash (cost=11.41..11.41 rows=100 width=4) (actual time=0.437..0.437 rows=589 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 29kB
8. 0.129 0.332 ↓ 5.9 589 1

Result (cost=0.14..10.41 rows=100 width=4) (actual time=0.126..0.332 rows=589 loops=1)

9. 0.187 0.203 ↓ 5.9 589 1

ProjectSet (cost=0.14..8.66 rows=100 width=32) (actual time=0.118..0.203 rows=589 loops=1)

10. 0.016 0.016 ↑ 1.0 1 1

Index Scan using users_pkey on users (cost=0.14..8.15 rows=1 width=194) (actual time=0.015..0.016 rows=1 loops=1)

  • Index Cond: (id = 2)
11. 1.178 1.178 ↑ 1.0 1 589

Index Scan using opta_players_pkey on opta_players p (cost=0.28..1.87 rows=1 width=883) (actual time=0.002..0.002 rows=1 loops=589)

  • Index Cond: (id = c.player_id)
12. 0.012 0.024 ↑ 1.0 20 1

Hash (cost=2.20..2.20 rows=20 width=11) (actual time=0.024..0.024 rows=20 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
13. 0.012 0.012 ↑ 1.0 20 1

Seq Scan on opta_teams t (cost=0.00..2.20 rows=20 width=11) (actual time=0.008..0.012 rows=20 loops=1)

14. 0.008 0.243 ↑ 25.0 4 1

Hash (cost=42.22..42.22 rows=100 width=8) (actual time=0.243..0.243 rows=4 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
15. 0.001 0.235 ↑ 25.0 4 1

Subquery Scan on ANY_subquery (cost=0.00..42.22 rows=100 width=8) (actual time=0.233..0.235 rows=4 loops=1)

16. 0.012 0.234 ↑ 25.0 4 1

ProjectSet (cost=0.00..41.22 rows=100 width=12) (actual time=0.232..0.234 rows=4 loops=1)

17. 0.021 0.222 ↑ 1.0 1 1

GroupAggregate (cost=0.00..40.71 rows=1 width=68) (actual time=0.222..0.222 rows=1 loops=1)

  • Group Key: e.id
18. 0.111 0.201 ↑ 5.0 2 1

Nested Loop (cost=0.00..40.62 rows=10 width=20) (actual time=0.104..0.201 rows=2 loops=1)

  • Join Filter: (f.id = ANY (e.fixtures))
  • Rows Removed by Join Filter: 378
19. 0.009 0.009 ↑ 1.0 1 1

Seq Scan on events e (cost=0.00..2.27 rows=1 width=43) (actual time=0.008..0.009 rows=1 loops=1)

  • Filter: (id = 25)
  • Rows Removed by Filter: 10
20. 0.081 0.081 ↑ 1.0 380 1

Seq Scan on opta_fixtures f (cost=0.00..29.80 rows=380 width=20) (actual time=0.004..0.081 rows=380 loops=1)