explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Qcov

Settings

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Sort (cost=1,763.93..1,763.94 rows=5 width=560) (actual rows= loops=)

  • Sort Key: cn.companyname, pn.name
2. 0.000 0.000 ↓ 0.0

Nested Loop (cost=2.94..1,763.87 rows=5 width=560) (actual rows= loops=)

3. 0.000 0.000 ↓ 0.0

Index Scan using pk_report on report r (cost=0.27..2.29 rows=1 width=14) (actual rows= loops=)

  • Index Cond: (reportkey = '941631848'::bpchar)
4. 0.000 0.000 ↓ 0.0

Nested Loop (cost=2.66..1,761.53 rows=5 width=560) (actual rows= loops=)

5. 0.000 0.000 ↓ 0.0

Index Scan using sessions_sessionhash on sessions s (cost=0.28..2.30 rows=1 width=45) (actual rows= loops=)

  • Index Cond: ((sessionhash)::text = '196039550ba35a68379c5067ba8d7bd5'::text)
  • Filter: (personid = '298121'::bpchar)
6. 0.000 0.000 ↓ 0.0

Nested Loop (cost=2.38..1,759.18 rows=5 width=560) (actual rows= loops=)

  • Join Filter: (((pp.payunitid)::character varying)::bpchar = ad.payunitid)
7. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=2.13..1,731.43 rows=1 width=564) (actual rows= loops=)

  • Join Filter: (tfs.taxfilingstatus = pte.taxfilingstatus)
8. 0.000 0.000 ↓ 0.0

Nested Loop (cost=2.13..1,729.64 rows=1 width=422) (actual rows= loops=)

  • Join Filter: ((a.asofdate >= pp.effectivedate) AND (a.asofdate <= pp.enddate))
9. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.84..1,728.89 rows=1 width=422) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.43..1,728.39 rows=1 width=424) (actual rows= loops=)

  • Join Filter: ((a.asofdate >= pn.effectivedate) AND (a.asofdate <= pn.enddate))
11. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.14..1,727.33 rows=1 width=345) (actual rows= loops=)

12. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.86..1,726.87 rows=1 width=93) (actual rows= loops=)

13. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.58..1,724.58 rows=4 width=89) (actual rows= loops=)

14. 0.000 0.000 ↓ 0.0

Index Scan using taxtaxcode on tax t (cost=0.29..55.17 rows=56 width=54) (actual rows= loops=)

  • Index Cond: (taxcode = 'ER_SUTA000'::bpchar)
15. 0.000 0.000 ↓ 0.0

Index Scan using person_tax_elections_taxid on person_tax_elections pte (cost=0.29..29.80 rows=1 width=39) (actual rows= loops=)

  • Index Cond: (taxid = t.taxid)
  • Filter: ((exempt = 'Y'::bpchar) AND (CURRENT_TIMESTAMP >= createts) AND (CURRENT_TIMESTAMP <= endts))
16. 0.000 0.000 ↓ 0.0

Index Only Scan using asof_pkey on asof a (cost=0.29..0.52 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((asofdate >= pte.effectivedate) AND (asofdate <= pte.enddate) AND (asofdate = '2020-01-01'::date))
17. 0.000 0.000 ↓ 0.0

Index Scan using companyname_pkey on companyname cn (cost=0.28..0.45 rows=1 width=260) (actual rows= loops=)

  • Index Cond: (companyid = pte.companyid)
  • Filter: ((CURRENT_DATE >= effectivedate) AND (CURRENT_DATE <= enddate) AND (CURRENT_TIMESTAMP >= createts) AND (CURRENT_TIMESTAMP <= endts))
18. 0.000 0.000 ↓ 0.0

Index Scan using person_names_personid_idx on person_names pn (cost=0.29..1.04 rows=1 width=87) (actual rows= loops=)

  • Index Cond: (personid = pte.personid)
  • Filter: ((nametype = 'Legal'::bpchar) AND (CURRENT_TIMESTAMP >= createts) AND (CURRENT_TIMESTAMP <= endts))
19. 0.000 0.000 ↓ 0.0

Index Scan using person_identity_pkey on person_identity pi (cost=0.41..0.49 rows=1 width=24) (actual rows= loops=)

  • Index Cond: ((personid = pn.personid) AND (identitytype = 'NetId'::bpchar))
  • Filter: ((CURRENT_TIMESTAMP >= createts) AND (CURRENT_TIMESTAMP <= endts))
20. 0.000 0.000 ↓ 0.0

Index Scan using person_payroll_personid_idx on person_payroll pp (cost=0.29..0.73 rows=1 width=25) (actual rows= loops=)

  • Index Cond: (personid = pte.personid)
  • Filter: ((CURRENT_TIMESTAMP >= createts) AND (CURRENT_TIMESTAMP <= endts))
21. 0.000 0.000 ↓ 0.0

Seq Scan on tax_filing_status tfs (cost=0.00..1.35 rows=35 width=150) (actual rows= loops=)

22. 0.000 0.000 ↓ 0.0

Function Scan on ah_payrolladmin_reportdomain_access_data ad (cost=0.25..10.25 rows=1,000 width=32) (actual rows= loops=)