explain.depesz.com

PostgreSQL's explain analyze made readable

Result: ZVf5

Settings
# exclusive inclusive rows x rows loops node
1. 0.004 221,100.289 ↓ 0.0 0 1

Delete on public.persons (cost=1,851,453.02..1,860,629.24 rows=1,203 width=102) (actual time=221,100.275..221,100.289 rows=0 loops=1)

2. 0.001 221,100.285 ↓ 0.0 0 1

Nested Loop (cost=1,851,453.02..1,860,629.24 rows=1,203 width=102) (actual time=221,100.272..221,100.285 rows=0 loops=1)

  • Output: persons.ctid, r.ctid, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid, fast_access_scens.ctid, form_perms.ctid, imported_recipient.ctid, recip_resp_stats.ctid,
  • Inner Unique: true
3. 0.029 221,100.284 ↓ 0.0 0 1

HashAggregate (cost=1,851,452.58..1,851,479.25 rows=2,667 width=104) (actual time=221,100.272..221,100.284 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid, fast_access_scens.ctid, form_perms.ctid, imported_recipient.ctid, recip_resp_stat
  • Group Key: r.recipient_id
4. 0.001 221,100.255 ↓ 0.0 0 1

Nested Loop Anti Join (cost=3.30..1,851,445.92 rows=2,667 width=104) (actual time=221,100.243..221,100.255 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid, fast_access_scens.ctid, form_perms.ctid, imported_recipient.ctid, recip_res
5. 0.002 221,100.254 ↓ 0.0 0 1

Merge Anti Join (cost=3.01..1,850,625.75 rows=2,667 width=98) (actual time=221,100.243..221,100.254 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid, fast_access_scens.ctid, form_perms.ctid, imported_recipient.ctid, rec
  • Merge Cond: (r.recipient_id = form_perms.person_id)
6. 0.002 221,100.252 ↓ 0.0 0 1

Nested Loop Anti Join (cost=2.29..1,850,595.34 rows=2,667 width=92) (actual time=221,100.241..221,100.252 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid, fast_access_scens.ctid, imported_recipient.ctid, recip_resp_sta
7. 0.002 221,100.250 ↓ 0.0 0 1

Nested Loop Anti Join (cost=1.87..1,845,330.47 rows=2,667 width=86) (actual time=221,100.240..221,100.250 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid, fast_access_scens.ctid, imported_recipient.ctid, recip_re
8. 0.002 221,100.248 ↓ 0.0 0 1

Nested Loop Anti Join (cost=1.58..1,844,510.22 rows=2,667 width=80) (actual time=221,100.239..221,100.248 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid, fast_access_scens.ctid, imported_recipient.ctid, re
  • Join Filter: (r.recipient_id = recip_resp_stats.recip_id)
9. 0.002 221,100.246 ↓ 0.0 0 1

Merge Anti Join (cost=1.58..1,844,349.15 rows=2,667 width=74) (actual time=221,100.238..221,100.246 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid, fast_access_scens.ctid, imported_recipient.ct
  • Merge Cond: (r.recipient_id = imported_recipient.recipient_id)
10. 0.002 221,100.244 ↓ 0.0 0 1

Nested Loop Anti Join (cost=1.43..1,844,311.82 rows=2,667 width=68) (actual time=221,100.236..221,100.244 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid, fast_access_scens.ctid
  • Join Filter: (r.recipient_id = fast_access_scens.person_id)
11. 0.002 221,100.242 ↓ 0.0 0 1

Nested Loop Anti Join (cost=1.43..1,835,898.15 rows=2,667 width=62) (actual time=221,100.235..221,100.242 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid, evs_tml.ctid
  • Join Filter: (r.recipient_id = evs_tml.owner)
12. 0.002 221,100.240 ↓ 0.0 0 1

Nested Loop Anti Join (cost=1.43..1,835,087.80 rows=2,667 width=56) (actual time=221,100.234..221,100.240 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid, ev_recipient_so.ctid
  • Join Filter: (r.recipient_id = ev_recipient_so.recipient_id)
13. 0.001 221,100.238 ↓ 0.0 0 1

Nested Loop Anti Join (cost=1.43..1,829,475.35 rows=2,667 width=50) (actual time=221,100.233..221,100.238 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid, em2.ctid
  • Join Filter: (r.recipient_id = em2.launcher_id)
14. 0.002 221,100.237 ↓ 0.0 0 1

Nested Loop Anti Join (cost=1.43..1,828,665.00 rows=2,667 width=44) (actual time=221,100.232..221,100.237 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid, em1.ctid
  • Join Filter: (r.recipient_id = em1.halter_id)
15. 0.001 221,100.235 ↓ 0.0 0 1

Merge Anti Join (cost=1.43..1,827,854.65 rows=2,667 width=38) (actual time=221,100.232..221,100.235 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid, enh_msg_recipients.ctid
  • Merge Cond: (r.recipient_id = enh_msg_recipients.recipient_id)
16. 0.003 221,100.234 ↓ 0.0 0 1

Merge Anti Join (cost=1.28..1,827,810.32 rows=2,667 width=32) (actual time=221,100.230..221,100.234 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid, enh_msg_monitors.ctid
  • Merge Cond: (r.recipient_id = enh_msg_monitors.person_id)
17. 0.002 221,100.231 ↓ 0.0 0 1

Nested Loop Left Join (cost=1.12..1,827,763.19 rows=2,667 width=26) (actual time=221,100.228..221,100.231 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid, dvc.ctid
18. 221,100.229 221,100.229 ↓ 0.0 0 1

Nested Loop Left Join (cost=0.56..1,783,801.00 rows=2,667 width=20) (actual time=221,100.227..221,100.229 rows=0 loops=1)

  • Output: r.ctid, r.recipient_id, contact_sessions.ctid
  • Join Filter: (r.recipient_id = contact_sessions.person_id)
  • -> Index Scan using recipients_recipid_person_deleted_pidx on public.recipients r (cost=0.56..1780189.43 rows=2,667 width=14) (actual time=221,100.225..221100.2
  • Output: r.ctid, r.recipient_id
  • Filter: ((r.deleted_id <> '-1'::integer) AND (r.when_updated <= '0201-12-24 23:30:06.291+00'::timestamp with time zone) AND ((r.recipient_cat)::text = 'PE
  • Rows Removed by Filter: 26,708,116
19. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..11.35 rows=90 width=14) (never executed)

  • Output: contact_sessions.ctid, contact_sessions.person_id
20. 0.000 0.000 ↓ 0.0 0

Seq Scan on public.contact_sessions (cost=0.00..10.90 rows=90 width=14) (never executed)

  • Output: contact_sessions.ctid, contact_sessions.person_id
21. 0.000 0.000 ↓ 0.0 0

Index Scan using idx_dvc2 on public.dvc (cost=0.56..15.63 rows=85 width=14) (never executed)

  • Output: dvc.ctid, dvc.person_id
  • Index Cond: (dvc.person_id = r.recipient_id)
22. 0.000 0.000 ↓ 0.0 0

Index Scan using idx_enh_msg_monitors2 on public.enh_msg_monitors (cost=0.15..37.05 rows=1,360 width=14) (never executed)

  • Output: enh_msg_monitors.ctid, enh_msg_monitors.person_id
23. 0.000 0.000 ↓ 0.0 0

Index Scan using idx_enh_msg_recipients2 on public.enh_msg_recipients (cost=0.15..34.65 rows=1,200 width=14) (never executed)

  • Output: enh_msg_recipients.ctid, enh_msg_recipients.recipient_id
24. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..10.30 rows=20 width=14) (never executed)

  • Output: em1.ctid, em1.halter_id
25. 0.000 0.000 ↓ 0.0 0

Seq Scan on public.enh_msgs em1 (cost=0.00..10.20 rows=20 width=14) (never executed)

  • Output: em1.ctid, em1.halter_id
26. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..10.30 rows=20 width=14) (never executed)

  • Output: em2.ctid, em2.launcher_id
27. 0.000 0.000 ↓ 0.0 0

Seq Scan on public.enh_msgs em2 (cost=0.00..10.20 rows=20 width=14) (never executed)

  • Output: em2.ctid, em2.launcher_id
28. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..12.10 rows=140 width=14) (never executed)

  • Output: ev_recipient_so.ctid, ev_recipient_so.recipient_id
29. 0.000 0.000 ↓ 0.0 0

Seq Scan on public.ev_recipient_so (cost=0.00..11.40 rows=140 width=14) (never executed)

  • Output: ev_recipient_so.ctid, ev_recipient_so.recipient_id
30. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..10.30 rows=20 width=14) (never executed)

  • Output: evs_tml.ctid, evs_tml.owner
31. 0.000 0.000 ↓ 0.0 0

Seq Scan on public.evs_tml (cost=0.00..10.20 rows=20 width=14) (never executed)

  • Output: evs_tml.ctid, evs_tml.owner
32. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..13.15 rows=210 width=14) (never executed)

  • Output: fast_access_scens.ctid, fast_access_scens.person_id
33. 0.000 0.000 ↓ 0.0 0

Seq Scan on public.fast_access_scens (cost=0.00..12.10 rows=210 width=14) (never executed)

  • Output: fast_access_scens.ctid, fast_access_scens.person_id
34. 0.000 0.000 ↓ 0.0 0

Index Scan using idx_imported_recipient_id on public.imported_recipient (cost=0.15..28.65 rows=800 width=14) (never executed)

  • Output: imported_recipient.ctid, imported_recipient.recipient_id
35. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..1.06 rows=4 width=14) (never executed)

  • Output: recip_resp_stats.ctid, recip_resp_stats.recip_id
36. 0.000 0.000 ↓ 0.0 0

Seq Scan on public.recip_resp_stats (cost=0.00..1.04 rows=4 width=14) (never executed)

  • Output: recip_resp_stats.ctid, recip_resp_stats.recip_id
37. 0.000 0.000 ↓ 0.0 0

Index Scan using idx_recipient_ntfn5 on public.recipient_ntfn (cost=0.29..225.99 rows=12,865 width=14) (never executed)

  • Output: recipient_ntfn.ctid, recipient_ntfn.recipient_id
  • Index Cond: (recipient_ntfn.recipient_id = r.recipient_id)
38. 0.000 0.000 ↓ 0.0 0

Index Scan using idx_sns3 on public.sns (cost=0.42..1.97 rows=1 width=14) (never executed)

  • Output: sns.ctid, sns.last_update_recipient_id
  • Index Cond: (sns.last_update_recipient_id = r.recipient_id)
39. 0.000 0.000 ↓ 0.0 0

Index Scan using idx_form_perm_pers on public.form_perms (cost=0.27..22.55 rows=473 width=14) (never executed)

  • Output: form_perms.ctid, form_perms.person_id
40. 0.000 0.000 ↓ 0.0 0

Index Scan using idx_sns_recipients2 on public.sns_recipients (cost=0.29..338.17 rows=19,296 width=14) (never executed)

  • Output: sns_recipients.ctid, sns_recipients.recipient_id
  • Index Cond: (sns_recipients.recipient_id = r.recipient_id)
41. 0.000 0.000 ↓ 0.0 0

Index Scan using persons_pk on public.persons (cost=0.44..3.43 rows=1 width=14) (never executed)

  • Output: persons.ctid, persons.person_id
  • Index Cond: (persons.person_id = r.recipient_id)
Planning time : 112.404 ms
Execution time : 221,103.639 ms