explain.depesz.com

PostgreSQL's explain analyze made readable

Result: ACSU

Settings
# exclusive inclusive rows x rows loops node
1. 0.005 34,462.955 ↓ 0.0 0 1

Delete on audit_evs_all_original aea (cost=7,924.23..182,798.56 rows=1 width=38) (actual time=34,462.939..34,462.955 rows=0 loops=1)

2. 0.001 34,462.950 ↓ 0.0 0 1

Nested Loop (cost=7,924.23..182,798.56 rows=1 width=38) (actual time=34,462.936..34,462.950 rows=0 loops=1)

3. 0.001 34,462.949 ↓ 0.0 0 1

Subquery Scan on aea2 (cost=7,923.80..182,708.73 rows=26 width=40) (actual time=34,462.935..34,462.949 rows=0 loops=1)

4. 0.002 34,462.948 ↓ 0.0 0 1

Limit (cost=7,923.80..182,708.47 rows=26 width=8) (actual time=34,462.934..34,462.948 rows=0 loops=1)

5. 0.016 34,462.946 ↓ 0.0 0 1

Hash Left Join (cost=7,923.80..182,708.47 rows=26 width=8) (actual time=34,462.932..34,462.946 rows=0 loops=1)

  • Hash Cond: (aea_1.ev_id = evs.ev_id)
  • Filter: (((aea_1.ev_id IS NOT NULL) AND (evs.ev_id IS NULL)) OR (aea_1.ev_id IS NULL))
6. 34,090.099 34,462.930 ↓ 0.0 0 1

Bitmap Heap Scan on audit_evs_all_original aea_1 (cost=1,116.14..174,413.06 rows=86,379 width=16) (actual time=34,462.928..34,462.930 rows=0 loops=1)

  • Recheck Cond: (((when_created <= '2020-07-25 12:15:21.635-07'::timestamp with time zone) AND (ev_id IS NOT NULL)) OR (ev_id IS NULL))
  • Filter: (when_created <= '2020-07-25 12:15:21.635-07'::timestamp with time zone)
  • Rows Removed by Filter: 3,500
  • Heap Blocks: exact=2,720
7. 0.006 372.831 ↓ 0.0 0 1

BitmapOr (cost=1,116.14..1,116.14 rows=89,127 width=0) (actual time=372.830..372.831 rows=0 loops=1)

8. 260.971 260.971 ↑ 1.1 79,320 1

Bitmap Index Scan on idx_audit_evs_all_when_created_ev_id_is_null_original (cost=0.00..1,030.59 rows=86,354 width=0) (actual time=260.971..260.971 rows=79,320 loops=1)

  • Index Cond: (when_created <= '2020-07-25 12:15:21.635-07'::timestamp with time zone)
9. 111.854 111.854 ↓ 1.3 3,721 1

Bitmap Index Scan on idx_audit_evs_all_epd_original (cost=0.00..42.37 rows=2,774 width=0) (actual time=111.854..111.854 rows=3,721 loops=1)

  • Index Cond: (ev_id IS NULL)
10. 0.000 0.000 ↓ 0.0 0

Hash (cost=5,059.18..5,059.18 rows=106,518 width=8) (never executed)

11. 0.000 0.000 ↓ 0.0 0

Seq Scan on evs (cost=0.00..5,059.18 rows=106,518 width=8) (never executed)

12. 0.000 0.000 ↓ 0.0 0

Index Scan using audit_evs_all_pk_original on audit_evs_all_original aea (cost=0.43..3.46 rows=1 width=14) (never executed)

  • Index Cond: (audit_ev_id = aea2.audit_ev_id)
  • Filter: (when_created <= '2020-07-25 12:15:21.635-07'::timestamp with time zone)
Planning time : 1,703.559 ms
Execution time : 34,463.125 ms