explain.depesz.com

PostgreSQL's explain analyze made readable

Result: dvqZ

Settings
# exclusive inclusive rows x rows loops node
1. 0.008 1,126,779.669 ↓ 30.0 30 1

Limit (cost=128.38..128.38 rows=1 width=6,605) (actual time=1,126,779.653..1,126,779.669 rows=30 loops=1)

2. 873.480 1,126,779.661 ↓ 30.0 30 1

Sort (cost=128.38..128.38 rows=1 width=6,605) (actual time=1,126,779.650..1,126,779.661 rows=30 loops=1)

  • Sort Key: "MdChapter".id
  • Sort Method: top-N heapsort Memory: 154kB
3. 207,493.853 1,125,906.181 ↓ 144,665.0 144,665 1

Nested Loop Left Join (cost=0.71..128.37 rows=1 width=6,605) (actual time=37.921..1,125,906.181 rows=144,665 loops=1)

  • Join Filter: ("MdChapter".md_comic_id = "MdComic".id)
  • Rows Removed by Join Filter: 2575260934
4. 1,959.553 1,959.553 ↓ 144,665.0 144,665 1

Index Scan using md_chapters_chapter_id_crawled_crawl_status on md_chapters "MdChapter" (cost=0.42..120.05 rows=1 width=4,233) (actual time=0.161..1,959.553 rows=144,665 loops=1)

  • Index Cond: ((crawled = false) AND (crawl_status IS NULL))
  • Filter: ((NOT crawled) AND (images IS NOT NULL) AND (id <> 387203) AND ((status)::text = 'OK'::text))
  • Rows Removed by Filter: 20142
5. 916,452.775 916,452.775 ↓ 17,802.0 17,802 144,665

Index Scan using md_comics_deleted_at_hentai_idx on md_comics "MdComic" (cost=0.29..8.31 rows=1 width=2,372) (actual time=0.016..6.335 rows=17,802 loops=144,665)

  • Index Cond: ((deleted_at IS NULL) AND (hentai = 0))
Planning time : 0.672 ms
Execution time : 1,126,779.747 ms