explain.depesz.com

PostgreSQL's explain analyze made readable

Result: tQPI : Optimization for: Optimization for: plan #4NSv; plan #n6RJ

Settings

Optimization path:

# exclusive inclusive rows x rows loops node
1. 913.263 2,355.369 ↓ 0.0 0 1

Delete on audit_evs_all_arc todel (cost=6,087.04..1,482,059.50 rows=414,543 width=12) (actual time=2,355.369..2,355.369 rows=0 loops=1)

2. 173.886 1,442.106 ↑ 1.2 359,121 1

Nested Loop (cost=6,087.04..1,482,059.50 rows=414,543 width=12) (actual time=30.216..1,442.106 rows=359,121 loops=1)

3. 162.439 190.857 ↑ 1.2 359,121 1

Bitmap Heap Scan on audit_evs_all_arc (cost=6,086.48..470,857.06 rows=414,543 width=14) (actual time=30.195..190.857 rows=359,121 loops=1)

  • Recheck Cond: ((when_created <= '2020-07-14 02:30:22.661+00'::timestamp with time zone) OR (when_created IS NULL))
  • Heap Blocks: exact=13,344
4. 0.002 28.418 ↓ 0.0 0 1

BitmapOr (cost=6,086.48..6,086.48 rows=414,543 width=0) (actual time=28.418..28.418 rows=0 loops=1)

5. 28.242 28.242 ↑ 1.2 359,121 1

Bitmap Index Scan on idx_audit_evs_arc_wc (cost=0.00..5,877.14 rows=414,543 width=0) (actual time=28.242..28.242 rows=359,121 loops=1)

  • Index Cond: (when_created <= '2020-07-14 02:30:22.661+00'::timestamp with time zone)
6. 0.174 0.174 ↓ 0.0 0 1

Bitmap Index Scan on idx_audit_evs_arc_wc (cost=0.00..2.07 rows=1 width=0) (actual time=0.174..0.174 rows=0 loops=1)

  • Index Cond: (when_created IS NULL)
7. 1,077.363 1,077.363 ↑ 1.0 1 359,121

Index Scan using audit_evs_all_arc_pk on audit_evs_all_arc todel (cost=0.56..2.44 rows=1 width=14) (actual time=0.003..0.003 rows=1 loops=359,121)

  • Index Cond: (audit_ev_id = audit_evs_all_arc.audit_ev_id)
Planning time : 0.331 ms
Execution time : 2,355.487 ms