explain.depesz.com

PostgreSQL's explain analyze made readable

Result: zqEj

Settings
# exclusive inclusive rows x rows loops node
1. 0.003 6,012.320 ↑ 1.0 20 1

Limit (cost=21,574.61..21,574.66 rows=20 width=85) (actual time=6,012.314..6,012.320 rows=20 loops=1)

  • Buffers: shared dirtied=481 hit=5348 read=5542
2. 4.647 6,012.317 ↑ 47.8 20 1

Sort (cost=21,574.61..21,577.00 rows=956 width=85) (actual time=6,012.312..6,012.317 rows=20 loops=1)

  • Sort Key: (COALESCE(issue_metrics.first_associated_with_milestone_at, issue_metrics.first_added_to_board_at)) DESC
  • Sort Method: top-N heapsort Memory: 28kB
  • Buffers: shared dirtied=481 hit=5348 read=5542
3. 14.031 6,007.670 ↓ 2.0 1,919 1

Nested Loop (cost=1.00..21,549.17 rows=956 width=85) (actual time=58.451..6,007.670 rows=1,919 loops=1)

  • Buffers: shared dirtied=481 hit=5345 read=5542
4. 2,608.544 2,608.544 ↑ 1.6 2,163 1

Index Scan using index_issues_on_project_id_and_created_at_and_id_and_state on public.issues (cost=0.56..6,369.93 rows=3,481 width=69) (actual time=39.405..2,608.544 rows=2,163 loops=1)

  • Index Cond: ((issues.project_id = 13083) AND (issues.created_at >= '2019-06-05 04:49:52.04309+00'::timestamp with time zone))
  • Buffers: shared dirtied=166 hit=84 read=2138
5. 3,385.095 3,385.095 ↑ 1.0 1 2,163

Index Scan using index_issue_metrics on public.issue_metrics (cost=0.43..4.35 rows=1 width=20) (actual time=1.562..1.565 rows=1 loops=2,163)

  • Index Cond: (issue_metrics.issue_id = issues.id)
  • Filter: (((COALESCE(issue_metrics.first_associated_with_milestone_at, issue_metrics.first_added_to_board_at))::timestamp with time zone - issues.created_at) > '00:00:00'::interval)
  • Rows Removed by Filter: 0
  • Buffers: shared dirtied=315 hit=5261 read=3404
Planning time : 2.511 ms