explain.depesz.com

PostgreSQL's explain analyze made readable

Result: cCvm

Settings

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 34.939 155.966 ↓ 1.2 68,112 1

Sort (cost=34,853.59..34,999.13 rows=58,215 width=77) (actual time=151.147..155.966 rows=68,112 loops=1)

  • Sort Key: e.id
  • Sort Method: quicksort Memory: 12504kB
2. 8.789 121.027 ↓ 1.2 68,112 1

Result (cost=0.00..30,246.14 rows=58,215 width=77) (actual time=0.306..121.027 rows=68,112 loops=1)

3. 4.440 112.238 ↓ 1.2 68,112 1

Append (cost=0.00..29,663.99 rows=58,215 width=76) (actual time=0.305..112.238 rows=68,112 loops=1)

4. 0.001 0.001 ↓ 0.0 0 1

Seq Scan on event e (cost=0.00..0.00 rows=1 width=76) (actual time=0.001..0.001 rows=0 loops=1)

  • Filter: ((NOT acknowledged) AND (event_time_utc > '2019-01-31 02:24:02.772413'::timestamp without time zone) AND (confirmation_state = 'pending'::enum_confirmation_state))
5. 75.970 75.970 ↓ 1.2 51,196 1

Index Scan using i_event_2019m02_unread on event_2019m02 e_1 (cost=0.41..21,465.85 rows=42,958 width=76) (actual time=0.304..75.970 rows=51,196 loops=1)

  • Filter: (event_time_utc > '2019-01-31 02:24:02.772413'::timestamp without time zone)
6. 0.034 4.046 ↑ 72.1 11 1

Bitmap Heap Scan on event_2019m01 e_2 (cost=1,085.36..4,050.02 rows=793 width=76) (actual time=4.027..4.046 rows=11 loops=1)

  • Recheck Cond: ((event_time_utc > '2019-01-31 02:24:02.772413'::timestamp without time zone) AND (NOT acknowledged) AND (confirmation_state = 'pending'::enum_confirmation_state))
  • Heap Blocks: exact=10
7. 0.773 4.012 ↓ 0.0 0 1

BitmapAnd (cost=1,085.36..1,085.36 rows=793 width=0) (actual time=4.012..4.012 rows=0 loops=1)

8. 3.071 3.071 ↓ 1.2 24,432 1

Bitmap Index Scan on i_event_2019m01_ts (cost=0.00..396.43 rows=20,267 width=0) (actual time=3.071..3.071 rows=24,432 loops=1)

  • Index Cond: (event_time_utc > '2019-01-31 02:24:02.772413'::timestamp without time zone)
9. 0.168 0.168 ↑ 61.3 505 1

Bitmap Index Scan on i_event_2019m01_unread (cost=0.00..688.29 rows=30,933 width=0) (actual time=0.168..0.168 rows=505 loops=1)

10. 27.781 27.781 ↓ 1.2 16,905 1

Index Scan using i_event_2019m03_unread on event_2019m03 e_3 (cost=0.29..4,148.12 rows=14,463 width=76) (actual time=0.011..27.781 rows=16,905 loops=1)

  • Filter: (event_time_utc > '2019-01-31 02:24:02.772413'::timestamp without time zone)