explain.depesz.com

PostgreSQL's explain analyze made readable

Result: vYlW

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Sort (cost=19,767.06..19,776.19 rows=3,650 width=34) (actual rows= loops=)

  • Output: u.id, u.display_name, (COALESCE(sum(c.rake), '0'::real)), (COALESCE((sum(c.hands))::real, '0'::real))
  • Sort Key: (COALESCE((sum(c.hands))::real, '0'::real)) DESC
2. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=19,495.78..19,551.10 rows=3,650 width=34) (actual rows= loops=)

  • Output: u.id, u.display_name, (COALESCE(sum(c.rake), '0'::real)), (COALESCE((sum(c.hands))::real, '0'::real))
  • Inner Unique: true
  • Hash Cond: (u_1.id = u.id)
3. 0.000 0.000 ↓ 0.0

Sort (cost=19,478.57..19,487.69 rows=3,650 width=30) (actual rows= loops=)

  • Output: u_1.id, c.season, (COALESCE((sum(c.hands))::real, '0'::real)), (COALESCE(sum(c.rake), '0'::real))
  • Sort Key: (COALESCE((sum(c.hands))::real, '0'::real)) DESC
4. 0.000 0.000 ↓ 0.0

HashAggregate (cost=19,216.98..19,262.60 rows=3,650 width=30) (actual rows= loops=)

  • Output: u_1.id, c.season, COALESCE((sum(c.hands))::real, '0'::real), COALESCE(sum(c.rake), '0'::real)
  • Group Key: c.season, u_1.id
5. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.00..18,854.55 rows=36,243 width=28) (actual rows= loops=)

  • Output: u_1.id, c.season, c.hands, c.rake
  • Join Filter: (c.pokerrr_id = ANY (u_1.pokerrr_ids))
6. 0.000 0.000 ↓ 0.0

Seq Scan on public.cash_games_players c (cost=0.00..308.11 rows=2,031 width=19) (actual rows= loops=)

  • Output: c.game_code, c.pokerrr_id, c.hands, c.profit, c.buy_in, c.rake, c.season
  • Filter: (c.season = '20-04-2'::text)
7. 0.000 0.000 ↓ 0.0

Materialize (cost=0.00..14.47 rows=365 width=50) (actual rows= loops=)

  • Output: u_1.id, u_1.pokerrr_ids
8. 0.000 0.000 ↓ 0.0

Seq Scan on public.users u_1 (cost=0.00..12.65 rows=365 width=50) (actual rows= loops=)

  • Output: u_1.id, u_1.pokerrr_ids
9. 0.000 0.000 ↓ 0.0

Hash (cost=12.65..12.65 rows=365 width=26) (actual rows= loops=)

  • Output: u.id, u.display_name
10. 0.000 0.000 ↓ 0.0

Seq Scan on public.users u (cost=0.00..12.65 rows=365 width=26) (actual rows= loops=)

  • Output: u.id, u.display_name