explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 4Yjt : Optimization for: plan #7SI6

Settings

Optimization path:

# exclusive inclusive rows x rows loops node
1. 0.037 5.827 ↑ 10.1 10 1

Sort (cost=119.65..119.90 rows=101 width=88) (actual time=5.822..5.827 rows=10 loops=1)

  • Sort Key: (sum(t.all_points)) DESC
  • Sort Method: quicksort Memory: 26kB
2. 2.225 5.790 ↑ 10.1 10 1

HashAggregate (cost=115.28..116.29 rows=101 width=88) (actual time=5.779..5.790 rows=10 loops=1)

  • Group Key: t.bettle_id, m.member_id
3. 1.750 3.565 ↓ 1.5 2,132 1

Hash Join (cost=14.66..60.45 rows=1,462 width=54) (actual time=0.733..3.565 rows=2,132 loops=1)

  • Hash Cond: (m.member_id = cm.member_id)
4. 0.811 1.314 ↑ 1.0 520 1

Hash Join (cost=5.27..31.89 rows=520 width=70) (actual time=0.216..1.314 rows=520 loops=1)

  • Hash Cond: (t.member_id = m.member_id)
5. 0.319 0.319 ↑ 1.0 520 1

Seq Scan on tip t (cost=0.00..25.20 rows=520 width=54) (actual time=0.008..0.319 rows=520 loops=1)

6. 0.094 0.184 ↑ 1.0 101 1

Hash (cost=4.01..4.01 rows=101 width=16) (actual time=0.184..0.184 rows=101 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 13kB
7. 0.090 0.090 ↑ 1.0 101 1

Seq Scan on member m (cost=0.00..4.01 rows=101 width=16) (actual time=0.006..0.090 rows=101 loops=1)

8. 0.270 0.501 ↑ 1.0 284 1

Hash (cost=5.84..5.84 rows=284 width=16) (actual time=0.501..0.501 rows=284 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 22kB
9. 0.231 0.231 ↑ 1.0 284 1

Seq Scan on club_member cm (cost=0.00..5.84 rows=284 width=16) (actual time=0.007..0.231 rows=284 loops=1)

Planning time : 0.598 ms
Execution time : 5.980 ms