explain.depesz.com

PostgreSQL's explain analyze made readable

Result: uVq6

Settings
# exclusive inclusive rows x rows loops node
1. 0.017 154.531 ↑ 1.0 1 1

Nested Loop Left Join (cost=134.03..72,469.03 rows=1 width=1,895) (actual time=154.529..154.531 rows=1 loops=1)

2. 0.011 154.499 ↑ 1.0 1 1

Nested Loop Left Join (cost=76.47..72,407.38 rows=1 width=1,301) (actual time=154.498..154.499 rows=1 loops=1)

3. 20.196 154.470 ↑ 1.0 1 1

Hash Right Join (cost=76.05..72,398.94 rows=1 width=1,292) (actual time=154.469..154.470 rows=1 loops=1)

  • Hash Cond: ((ed.service_request__r__externalid__c)::text = (sr.externalid__c)::text)
  • Join Filter: (((ed.service_request__c)::text = (sr.sfid)::text) OR ((COALESCE(sr.sfid, ''::character varying))::text = ''::text))
4. 134.168 134.168 ↓ 1.0 464,263 1

Seq Scan on emergency_dispatch__c ed (cost=0.00..70,582.09 rows=464,209 width=34) (actual time=0.004..134.168 rows=464,263 loops=1)

5. 0.006 0.106 ↑ 1.0 1 1

Hash (cost=76.03..76.03 rows=1 width=1,284) (actual time=0.106..0.106 rows=1 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
6. 0.001 0.100 ↑ 1.0 1 1

Nested Loop Left Join (cost=11.82..76.03 rows=1 width=1,284) (actual time=0.098..0.100 rows=1 loops=1)

7. 0.001 0.097 ↑ 1.0 1 1

Nested Loop Left Join (cost=11.40..67.59 rows=1 width=1,235) (actual time=0.096..0.097 rows=1 loops=1)

8. 0.002 0.075 ↑ 1.0 1 1

Nested Loop Left Join (cost=2.39..50.52 rows=1 width=1,147) (actual time=0.074..0.075 rows=1 loops=1)

9. 0.003 0.071 ↑ 1.0 1 1

Nested Loop Left Join (cost=2.11..42.22 rows=1 width=1,145) (actual time=0.071..0.071 rows=1 loops=1)

10. 0.004 0.059 ↑ 1.0 1 1

Nested Loop Left Join (cost=1.69..33.78 rows=1 width=965) (actual time=0.058..0.059 rows=1 loops=1)

11. 0.002 0.048 ↑ 1.0 1 1

Nested Loop Left Join (cost=1.41..25.48 rows=1 width=679) (actual time=0.047..0.048 rows=1 loops=1)

12. 0.004 0.031 ↑ 1.0 1 1

Nested Loop Left Join (cost=0.99..17.03 rows=1 width=478) (actual time=0.030..0.031 rows=1 loops=1)

13. 0.011 0.011 ↑ 1.0 1 1

Index Scan using service_request1__c_pkey on service_request1__c sr (cost=0.43..8.45 rows=1 width=463) (actual time=0.010..0.011 rows=1 loops=1)

  • Index Cond: (id = 2827522)
14. 0.016 0.016 ↑ 1.0 1 1

Index Scan using contact_idx_sfid on contact c (cost=0.56..8.58 rows=1 width=34) (actual time=0.016..0.016 rows=1 loops=1)

  • Index Cond: ((sfid)::text = (sr.property_consultant__c)::text)
  • Filter: ((recordtypeid)::text = '0120H000001O7IWQA0'::text)
15. 0.015 0.015 ↑ 1.0 1 1

Index Scan using property__c_idx_sfid on property__c p (cost=0.42..8.44 rows=1 width=220) (actual time=0.015..0.015 rows=1 loops=1)

  • Index Cond: ((sfid)::text = (sr.property_of_interest__c)::text)
  • Filter: ((account__c)::text = (sr.account_name__c)::text)
16. 0.007 0.007 ↑ 1.0 1 1

Index Scan using account_idx_sfid on account ac (cost=0.28..8.30 rows=1 width=305) (actual time=0.007..0.007 rows=1 loops=1)

  • Index Cond: ((sr.account_name__c)::text = (sfid)::text)
17. 0.009 0.009 ↑ 1.0 1 1

Index Scan using source__c_idx_sfid on source__c s (cost=0.42..8.44 rows=1 width=199) (actual time=0.009..0.009 rows=1 loops=1)

  • Index Cond: ((sfid)::text = (sr.source__c)::text)
18. 0.002 0.002 ↓ 0.0 0 1

Index Scan using work_order_dispatch__c_idx_sfid on work_order_dispatch__c wod (cost=0.29..8.30 rows=1 width=21) (actual time=0.002..0.002 rows=0 loops=1)

  • Index Cond: ((sr.work_order_dispatch__c)::text = (sfid)::text)
19. 0.008 0.021 ↑ 2.0 1 1

Bitmap Heap Scan on contact c1 (cost=9.01..17.04 rows=2 width=88) (actual time=0.020..0.021 rows=1 loops=1)

  • Recheck Cond: (((sr.contact_name__c)::text = (sfid)::text) OR ((sr.contact_name__r__externalid__c)::text = (externalid__c)::text))
  • Filter: ((((COALESCE(sfid, ''::character varying))::text <> ''::text) AND ((COALESCE(sr.contact_name__c, ''::character varying))::text <> ''::text) AND ((sr.contact_name__c)::text = (sfid)::text)) OR ((sr.contact_name_ (...)
  • Heap Blocks: exact=1
20. 0.002 0.013 ↓ 0.0 0 1

BitmapOr (cost=9.01..9.01 rows=2 width=0) (actual time=0.013..0.013 rows=0 loops=1)

21. 0.011 0.011 ↑ 1.0 1 1

Bitmap Index Scan on contact_idx_sfid (cost=0.00..4.57 rows=1 width=0) (actual time=0.011..0.011 rows=1 loops=1)

  • Index Cond: ((sr.contact_name__c)::text = (sfid)::text)
22. 0.000 0.000 ↓ 0.0 0 1

Bitmap Index Scan on hc_idx_contact_externalid__c (cost=0.00..4.44 rows=1 width=0) (actual time=0.000..0.000 rows=0 loops=1)

  • Index Cond: ((sr.contact_name__r__externalid__c)::text = (externalid__c)::text)
23. 0.002 0.002 ↓ 0.0 0 1

Index Scan using service_request_type__c_idx_sfid on service_request_type__c srt (cost=0.42..8.44 rows=1 width=87) (actual time=0.002..0.002 rows=0 loops=1)

  • Index Cond: ((sfid)::text = (sr.service_request_type__c)::text)
  • Filter: ((account__c)::text = (sr.account_name__c)::text)
24. 0.018 0.018 ↑ 1.0 1 1

Index Scan using unit__c_idx_sfid on unit__c u (cost=0.43..8.45 rows=1 width=28) (actual time=0.018..0.018 rows=1 loops=1)

  • Index Cond: ((sfid)::text = (sr.unit_needing_service__c)::text)
25. 0.001 0.015 ↓ 0.0 0 1

Bitmap Heap Scan on lease_data__c l (cost=57.55..61.60 rows=1 width=147) (actual time=0.015..0.015 rows=0 loops=1)

  • Recheck Cond: (((sr.property_of_interest__c)::text = (property__c)::text) AND (((sr.contact_name__c)::text = (lease_holder_1__c)::text) OR ((sr.contact_name__r__externalid__c)::text = (lease_holder_1__r__externalid__c)::text) OR ((sr.contact_name__ (...)
  • Filter: (((status__c)::text = ANY ('{Current,Resident}'::text[])) AND ((type__c)::text = 'Lease'::text) AND ((sr.account_name__c)::text = (account__c)::text) AND (((sr.contact_name__c)::text = (lease_holder_1__c)::text) OR (((COALESCE(lease_holder_ (...)
26. 0.002 0.014 ↓ 0.0 0 1

BitmapAnd (cost=57.55..57.55 rows=1 width=0) (actual time=0.014..0.014 rows=0 loops=1)

27. 0.012 0.012 ↓ 0.0 0 1

Bitmap Index Scan on hc_idx_lease_data__c_property__c (cost=0.00..21.72 rows=705 width=0) (actual time=0.012..0.012 rows=0 loops=1)

  • Index Cond: ((sr.property_of_interest__c)::text = (property__c)::text)
28. 0.000 0.000 ↓ 0.0 0

BitmapOr (cost=35.58..35.58 rows=19 width=0) (never executed)

29. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on hc_idx_lease_data__c_lease_holder_1__c (cost=0.00..4.44 rows=2 width=0) (never executed)

  • Index Cond: ((sr.contact_name__c)::text = (lease_holder_1__c)::text)
30. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on hc_idx_lease_data__c_lease_holder_1__r__externalid__c (cost=0.00..4.44 rows=2 width=0) (never executed)

  • Index Cond: ((sr.contact_name__r__externalid__c)::text = (lease_holder_1__r__externalid__c)::text)
31. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on hc_idx_lease_data__c_lease_holder_2__c (cost=0.00..4.44 rows=2 width=0) (never executed)

  • Index Cond: ((sr.contact_name__c)::text = (lease_holder_2__c)::text)
32. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on hc_idx_lease_data__c_lease_holder_2__r__externalid__c (cost=0.00..4.44 rows=2 width=0) (never executed)

  • Index Cond: ((sr.contact_name__r__externalid__c)::text = (lease_holder_2__r__externalid__c)::text)
33. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on hc_idx_lease_data__c_lease_holder_3__c (cost=0.00..4.45 rows=3 width=0) (never executed)

  • Index Cond: ((sr.contact_name__c)::text = (lease_holder_3__c)::text)
34. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on hc_idx_lease_data__c_lease_holder_3__r__externalid__c (cost=0.00..4.44 rows=2 width=0) (never executed)

  • Index Cond: ((sr.contact_name__r__externalid__c)::text = (lease_holder_3__r__externalid__c)::text)
35. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on hc_idx_lease_data__c_lease_holder_4__c (cost=0.00..4.46 rows=4 width=0) (never executed)

  • Index Cond: ((sr.contact_name__c)::text = (lease_holder_4__c)::text)
36. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on hc_idx_lease_data__c_lease_holder_4__r__externalid__c (cost=0.00..4.44 rows=2 width=0) (never executed)

  • Index Cond: ((sr.contact_name__r__externalid__c)::text = (lease_holder_4__r__externalid__c)::text)