explain.depesz.com

PostgreSQL's explain analyze made readable

Result: fzky : Optimization for: plan #xGFy

Settings

Optimization path:

# exclusive inclusive rows x rows loops node
1. 0.112 18.744 ↑ 1.0 1 1

Aggregate (cost=40.64..40.98 rows=1 width=5) (actual time=18.743..18.744 rows=1 loops=1)

  • Buffers: shared hit=7 read=19
  • I/O Timings: read=17.662
2. 0.097 3.937 ↑ 1.0 1,000 1

Limit (cost=0.44..25.64 rows=1,000 width=4) (actual time=3.630..3.937 rows=1,000 loops=1)

  • Buffers: shared hit=6 read=1
  • I/O Timings: read=3.498
3. 3.840 3.840 ↑ 15,532.9 1,000 1

Index Only Scan using lfs_objects_pkey on public.lfs_objects (cost=0.44..391,444.14 rows=15,532,942 width=4) (actual time=3.628..3.840 rows=1,000 loops=1)

  • Index Cond: (lfs_objects.id >= 7000000)
  • Heap Fetches: 0
  • Buffers: shared hit=6 read=1
  • I/O Timings: read=3.498
4.          

SubPlan (for Aggregate)

5. 14.695 14.695 ↑ 7,301,232.0 1 1

Seq Scan on public.lfs_objects lfs_objects_1 (cost=0.00..2,442,060.20 rows=7,301,232 width=0) (actual time=14.695..14.695 rows=1 loops=1)

  • Filter: (lfs_objects_1.id > max(lfs_objects.id))
  • Rows Removed by Filter: 748
  • Buffers: shared hit=1 read=18
  • I/O Timings: read=14.164