explain.depesz.com

PostgreSQL's explain analyze made readable

Result: hD2l

Settings
# exclusive inclusive rows x rows loops node
1. 0.003 8,851.846 ↑ 1.0 5 1

Limit (cost=112,232.57..112,232.69 rows=5 width=1,244) (actual time=8,851.840..8,851.846 rows=5 loops=1)

2. 0.005 8,851.843 ↑ 40.0 5 1

Unique (cost=112,232.57..112,237.53 rows=200 width=1,244) (actual time=8,851.838..8,851.843 rows=5 loops=1)

3. 68.124 8,851.838 ↑ 198.4 5 1

Sort (cost=112,232.57..112,235.05 rows=992 width=1,244) (actual time=8,851.837..8,851.838 rows=5 loops=1)

  • Sort Key: r.userid COLLATE "C", r.created DESC
  • Sort Method: quicksort Memory: 38079kB
4. 19.994 8,783.714 ↓ 68.5 67,973 1

Nested Loop Left Join (cost=544.45..112,183.20 rows=992 width=1,244) (actual time=257.137..8,783.714 rows=67,973 loops=1)

5. 39.014 8,695.747 ↓ 68.5 67,973 1

Nested Loop (cost=544.18..111,885.59 rows=992 width=1,203) (actual time=257.132..8,695.747 rows=67,973 loops=1)

6. 1,137.323 8,520.787 ↓ 68.5 67,973 1

Nested Loop (cost=543.63..107,792.63 rows=992 width=316) (actual time=257.122..8,520.787 rows=67,973 loops=1)

7. 783.490 4,445.560 ↓ 199.4 2,937,904 1

Nested Loop (cost=543.20..98,842.40 rows=14,737 width=320) (actual time=257.110..4,445.560 rows=2,937,904 loops=1)

8. 508.497 724.166 ↓ 199.4 2,937,904 1

Bitmap Heap Scan on omaha_apprequest ar (cost=542.77..44,092.22 rows=14,737 width=316) (actual time=257.088..724.166 rows=2,937,904 loops=1)

  • Recheck Cond: ((appid)::text = '{98DA7DF2-4E3E-4744-9DE6-EC931886ABAB}'::text)
  • Heap Blocks: exact=151300
9. 215.669 215.669 ↓ 199.4 2,937,904 1

Bitmap Index Scan on omaha_apprequest_7aa64062 (cost=0.00..539.08 rows=14,737 width=0) (actual time=215.669..215.669 rows=2,937,904 loops=1)

  • Index Cond: ((appid)::text = '{98DA7DF2-4E3E-4744-9DE6-EC931886ABAB}'::text)
10. 2,937.904 2,937.904 ↑ 1.0 1 2,937,904

Index Only Scan using omaha_apprequest_events_apprequest_id_fe1d45b7_uniq on omaha_apprequest_events ae (cost=0.43..3.71 rows=1 width=8) (actual time=0.001..0.001 rows=1 loops=2,937,904)

  • Index Cond: (apprequest_id = ar.id)
  • Heap Fetches: 0
11. 2,937.904 2,937.904 ↓ 0.0 0 2,937,904

Index Scan using omaha_event_pkey on omaha_event e (cost=0.43..0.60 rows=1 width=4) (actual time=0.001..0.001 rows=0 loops=2,937,904)

  • Index Cond: (id = ae.event_id)
  • Filter: ((eventtype = ANY ('{2,3}'::integer[])) AND (eventresult = 1))
  • Rows Removed by Filter: 1
12. 135.946 135.946 ↑ 1.0 1 67,973

Index Only Scan using omaha_request_version_4 on omaha_request r (cost=0.56..4.12 rows=1 width=887) (actual time=0.002..0.002 rows=1 loops=67,973)

  • Index Cond: (id = ar.request_id)
  • Heap Fetches: 0
13. 67.973 67.973 ↑ 1.0 1 67,973

Index Scan using omaha_os_pkey on omaha_os os (cost=0.27..0.29 rows=1 width=41) (actual time=0.001..0.001 rows=1 loops=67,973)

  • Index Cond: (r.os_id = id)