explain.depesz.com

PostgreSQL's explain analyze made readable

Result: R3VY

Settings
# exclusive inclusive rows x rows loops node
1. 0.156 2,900.753 ↓ 227.0 227 1

WindowAgg (cost=5,436.68..5,436.73 rows=1 width=127) (actual time=2,900.657..2,900.753 rows=227 loops=1)

2. 4.965 2,900.597 ↓ 227.0 227 1

GroupAggregate (cost=5,436.68..5,436.72 rows=1 width=55) (actual time=2,894.851..2,900.597 rows=227 loops=1)

  • Group Key: co.sfid, ip.team__c, co.firstname, co.lastname
3. 20.448 2,895.632 ↓ 22,419.0 22,419 1

Sort (cost=5,436.68..5,436.69 rows=1 width=72) (actual time=2,894.842..2,895.632 rows=22,419 loops=1)

  • Sort Key: co.sfid, ip.team__c, co.firstname, co.lastname
  • Sort Method: quicksort Memory: 3,738kB
4. 33.924 2,875.184 ↓ 22,419.0 22,419 1

Nested Loop (cost=3,089.05..5,436.67 rows=1 width=72) (actual time=12.245..2,875.184 rows=22,419 loops=1)

5. 1.598 3.920 ↓ 330.0 330 1

Hash Join (cost=72.77..2,255.73 rows=1 width=66) (actual time=0.484..3.920 rows=330 loops=1)

  • Hash Cond: ((co.sfid)::text = (ip.contact__c)::text)
6. 1.910 1.910 ↑ 12.9 812 1

Index Scan using hc_idx_contact_recordtypeid on contact co (cost=0.56..2,131.13 rows=10,476 width=34) (actual time=0.035..1.910 rows=812 loops=1)

  • Index Cond: ((recordtypeid)::text = '0120H000001O7IWQA0'::text)
7. 0.074 0.412 ↑ 1.0 331 1

Hash (cost=68.00..68.00 rows=337 width=32) (actual time=0.412..0.412 rows=331 loops=1)

  • Buckets: 1,024 Batches: 1 Memory Usage: 29kB
8. 0.338 0.338 ↑ 1.0 331 1

Seq Scan on internal_app_permissions__c ip (cost=0.00..68.00 rows=337 width=32) (actual time=0.007..0.338 rows=331 loops=1)

  • Filter: ((employment_status__c)::text = 'Active'::text)
  • Rows Removed by Filter: 455
9. 73.920 2,837.340 ↓ 34.0 68 330

Bitmap Heap Scan on "case" ca (cost=3,016.28..3,180.92 rows=2 width=44) (actual time=8.414..8.598 rows=68 loops=330)

  • Recheck Cond: (((property_consultant__c)::text = (co.sfid)::text) AND (createddate >= '2019-08-27 11:13:55'::timestamp without time zone) AND (createddate < '2019-09-26 11:13:55'::timestamp without time zone))
  • Filter: (ic_call_answered_by_ah__c AND (NOT COALESCE(resident_case__c, false)) AND ((status)::text <> 'Resident'::text) AND ((recordtypeid)::text = '012i0000000DVbcAAG'::text))
  • Rows Removed by Filter: 0
  • Heap Blocks: exact=22,477
10. 110.640 2,763.420 ↓ 0.0 0 330

BitmapAnd (cost=3,016.28..3,016.28 rows=43 width=0) (actual time=8.374..8.374 rows=0 loops=330)

11. 181.830 181.830 ↑ 1.0 4,984 330

Bitmap Index Scan on hc_idx_case_property_consultant__c (cost=0.00..95.45 rows=5,068 width=0) (actual time=0.551..0.551 rows=4,984 loops=330)

  • Index Cond: ((property_consultant__c)::text = (co.sfid)::text)
12. 2,470.950 2,470.950 ↑ 1.8 75,794 285

Bitmap Index Scan on hc_idx_case_createddate (cost=0.00..2,918.66 rows=139,023 width=0) (actual time=8.670..8.670 rows=75,794 loops=285)

  • Index Cond: ((createddate >= '2019-08-27 11:13:55'::timestamp without time zone) AND (createddate < '2019-09-26 11:13:55'::timestamp without time zone))
Planning time : 3.505 ms
Execution time : 2,901.172 ms