explain.depesz.com

PostgreSQL's explain analyze made readable

Result: nqFGK

Settings
# exclusive inclusive rows x rows loops node
1. 0.003 1,018.922 ↓ 5.0 5 1

Limit (cost=24.76..47,927,042.53 rows=1 width=66) (actual time=1,005.649..1,018.922 rows=5 loops=1)

2. 0.014 1,018.919 ↓ 5.0 5 1

Nested Loop Left Join (cost=24.76..47,927,042.53 rows=1 width=66) (actual time=1,005.648..1,018.919 rows=5 loops=1)

  • Filter: (ucmfrd.contactid IS NULL)
3. 9.310 9.310 ↑ 3,166.6 5 1

Seq Scan on contactsforrecommendations cfr (cost=0.00..50,864.10 rows=15,833 width=66) (actual time=2.139..9.310 rows=5 loops=1)

  • Filter: ((lower(titlename) = 'vp marketing'::text) OR ((length(titlename) > 4) AND (titlename % 'vp marketing'::text)) OR (lower(titlename) = 'marketing'::text) OR ((length(titlename) > 4) AND (titlename % 'marketing'::text)) OR (lower(titlename) = 'director'::text) OR ((length(titlename) > 4) AND (titlename % 'director'::text)) OR (lower(titlename) = 'marketing manager'::text) OR ((length(titlename) > 4) AND (titlename % 'marketing manager'::text)) OR (lower(titlename) = 'sales'::text) OR ((length(titlename) > 4) AND (titlename % 'sales'::text)))
  • Rows Removed by Filter: 170
4. 0.025 1,009.595 ↓ 0.0 0 5

Limit (cost=24.76..3,023.80 rows=1 width=8) (actual time=201.919..201.919 rows=0 loops=5)

5. 1,001.305 1,009.570 ↓ 0.0 0 5

Bitmap Heap Scan on usermycontactsforrecommdedupe ucmfrd (cost=24.76..3,023.80 rows=1 width=8) (actual time=201.914..201.914 rows=0 loops=5)

  • Recheck Cond: (userid = '8025'::bigint)
  • Filter: ((firstname = cfr.firstname) AND (companyname = cfr.companyname) AND ((cfr.lastname IS NULL) OR (lower(cfr.lastname) = lower(lastname))))
  • Rows Removed by Filter: 1079
  • Heap Blocks: exact=4105
6. 8.265 8.265 ↑ 1.9 1,079 5

Bitmap Index Scan on idx_usermycontactsforrecommdedupe_userid (cost=0.00..24.76 rows=2,043 width=0) (actual time=1.653..1.653 rows=1,079 loops=5)

  • Index Cond: (userid = '8025'::bigint)
Planning time : 5.558 ms
Execution time : 1,018.968 ms