explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 6REa

Settings
# exclusive inclusive rows x rows loops node
1. 0.006 493.202 ↓ 29.0 29 1

Unique (cost=52,082.20..52,082.21 rows=1 width=8) (actual time=493.192..493.202 rows=29 loops=1)

2. 0.044 493.196 ↓ 29.0 29 1

Sort (cost=52,082.20..52,082.21 rows=1 width=8) (actual time=493.191..493.196 rows=29 loops=1)

  • Sort Key: br.id
  • Sort Method: quicksort Memory: 26kB
3. 167.015 493.152 ↓ 29.0 29 1

Hash Left Join (cost=35,163.51..52,082.19 rows=1 width=8) (actual time=273.173..493.152 rows=29 loops=1)

  • Hash Cond: (br.cmid = cm.id)
  • Filter: ((c.id IS NULL) OR (cm.id IS NULL))
  • Rows Removed by Filter: 240949
4. 58.491 84.343 ↑ 1.0 240,978 1

Hash Left Join (cost=1,075.94..8,808.17 rows=240,978 width=24) (actual time=5.387..84.343 rows=240,978 loops=1)

  • Hash Cond: (br.courseid = c.id)
5. 20.751 20.751 ↑ 1.0 240,978 1

Seq Scan on mdl_block_recentlyaccesseditems br (cost=0.00..4,418.78 rows=240,978 width=24) (actual time=0.111..20.751 rows=240,978 loops=1)

6. 2.790 5.101 ↑ 1.5 11,546 1

Hash (cost=861.55..861.55 rows=17,151 width=8) (actual time=5.101..5.101 rows=11,546 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 708kB
7. 2.311 2.311 ↑ 1.5 11,546 1

Index Only Scan using mdl_cour_id_pk on mdl_course c (cost=0.29..861.55 rows=17,151 width=8) (actual time=0.008..2.311 rows=11,546 loops=1)

  • Heap Fetches: 0
8. 131.905 241.794 ↑ 1.0 780,470 1

Hash (cost=21,282.70..21,282.70 rows=780,470 width=8) (actual time=241.794..241.794 rows=780,470 loops=1)

  • Buckets: 131072 Batches: 16 Memory Usage: 2932kB
9. 109.889 109.889 ↑ 1.0 780,470 1

Seq Scan on mdl_course_modules cm (cost=0.00..21,282.70 rows=780,470 width=8) (actual time=0.109..109.889 rows=780,470 loops=1)

Planning time : 0.332 ms
Execution time : 493.570 ms