explain.depesz.com

PostgreSQL's explain analyze made readable

Result: nQAB

Settings
# exclusive inclusive rows x rows loops node
1. 42.980 66.917 ↑ 139.0 1 1

Seq Scan on contact (cost=0.00..65,457.69 rows=139 width=16) (actual time=63.557..66.917 rows=1 loops=1)

  • Filter: (CASE WHEN (primary_email_enum = 1) THEN (home_email_address1)::text WHEN (primary_email_enum = 2) THEN (home_email_address2)::text ELSE (SubPlan 2) END = 'ryan.orourke@alfordmedia.com'::text)
  • Rows Removed by Filter: 26832
2.          

SubPlan (forSeq Scan)

3. 0.005 0.005 ↑ 1.0 1 1

Index Scan using company_contact_pkey on company_contact (cost=0.00..2.29 rows=1 width=9) (actual time=0.004..0.005 rows=1 loops=1)

  • Index Cond: (contact.primary_email_id = id)
  • Filter: (NOT is_obsolete)
4. 23.932 23.932 ↓ 0.0 0 23,932

Index Scan using company_contact_pkey on company_contact (cost=0.00..2.29 rows=1 width=9) (actual time=0.001..0.001 rows=0 loops=23,932)

  • Index Cond: (contact.primary_email_id = id)
  • Filter: (NOT is_obsolete)
  • Rows Removed by Filter: 0