explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 62k2

Settings
# exclusive inclusive rows x rows loops node
1. 0.021 5,592.272 ↑ 1.0 51 1

Limit (cost=2,044,608.53..2,044,608.66 rows=51 width=735) (actual time=5,592.238..5,592.272 rows=51 loops=1)

  • Buffers: shared hit=125116 read=393526
2. 763.016 5,592.251 ↑ 15,863.2 51 1

Sort (cost=2,044,608.53..2,046,631.09 rows=809,024 width=735) (actual time=5,592.237..5,592.251 rows=51 loops=1)

  • Sort Key: date_uploaded, id
  • Sort Method: top-N heapsort Memory: 51kB
  • Buffers: shared hit=125116 read=393526
3. 4,574.643 4,829.235 ↑ 1.0 807,273 1

Bitmap Heap Scan on images (cost=30,391.62..2,017,617.77 rows=809,024 width=735) (actual time=421.481..4,829.235 rows=807,273 loops=1)

  • Recheck Cond: ((company_id = 1) AND (status = 2) AND (deleted_at IS NULL))
  • Heap Blocks: exact=513768
  • Buffers: shared hit=125110 read=393526
4. 254.592 254.592 ↑ 1.0 807,358 1

Bitmap Index Scan on by_company_status_deleted (cost=0.00..30,189.37 rows=809,024 width=0) (actual time=254.592..254.592 rows=807,358 loops=1)

  • Index Cond: ((company_id = 1) AND (status = 2) AND (deleted_at IS NULL))
  • Buffers: shared hit=7 read=4861