explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 8lXP

Settings
# exclusive inclusive rows x rows loops node
1. 0.004 0.204 ↑ 1.0 3 1

Limit (cost=3,337.09..3,337.09 rows=3 width=292) (actual time=0.201..0.204 rows=3 loops=1)

2. 0.053 0.200 ↑ 88.0 3 1

Sort (cost=3,337.09..3,337.75 rows=264 width=292) (actual time=0.200..0.200 rows=3 loops=1)

  • Sort Key: herald_activity."timestamp" DESC
  • Sort Method: quicksort Memory: 26kB
3. 0.011 0.147 ↑ 88.0 3 1

Nested Loop (cost=7.58..3,333.67 rows=264 width=292) (actual time=0.125..0.147 rows=3 loops=1)

4. 0.009 0.103 ↑ 88.0 3 1

Nested Loop (cost=7.29..3,251.65 rows=264 width=189) (actual time=0.090..0.103 rows=3 loops=1)

5. 0.024 0.024 ↑ 1.0 1 1

Index Scan using herald_user_pkey on herald_user (cost=0.29..8.31 rows=1 width=103) (actual time=0.023..0.024 rows=1 loops=1)

  • Index Cond: (id = 8008)
6. 0.008 0.070 ↑ 88.0 3 1

Nested Loop (cost=7.00..3,240.71 rows=264 width=86) (actual time=0.059..0.070 rows=3 loops=1)

7. 0.015 0.032 ↑ 92.3 3 1

Bitmap Heap Scan on herald_notification (cost=6.57..966.13 rows=277 width=14) (actual time=0.031..0.032 rows=3 loops=1)

  • Recheck Cond: (user_id = 8008)
  • Heap Blocks: exact=1
8. 0.017 0.017 ↑ 92.3 3 1

Bitmap Index Scan on herald_notification_user_id_dccf7862 (cost=0.00..6.51 rows=277 width=0) (actual time=0.016..0.017 rows=3 loops=1)

  • Index Cond: (user_id = 8008)
9. 0.030 0.030 ↑ 1.0 1 3

Index Scan using herald_activity_pkey on herald_activity (cost=0.42..8.21 rows=1 width=72) (actual time=0.010..0.010 rows=1 loops=3)

  • Index Cond: (id = herald_notification.activity_id)
  • Filter: active
10. 0.033 0.033 ↑ 1.0 1 3

Index Scan using herald_user_pkey on herald_user t4 (cost=0.29..0.31 rows=1 width=103) (actual time=0.011..0.011 rows=1 loops=3)

  • Index Cond: (id = herald_activity.actor_id)
Planning time : 2.819 ms
Execution time : 0.414 ms