explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 7qFJ

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 6.086 ↓ 44.0 44 1

Nested Loop (cost=1.42..8,985.86 rows=1 width=173) (actual time=5.941..6.086 rows=44 loops=1)

2. 0.176 0.961 ↓ 45.5 1,866 1

Nested Loop (cost=0.86..542.75 rows=41 width=4) (actual time=0.024..0.961 rows=1,866 loops=1)

3. 0.017 0.017 ↓ 3.0 3 1

Index Scan using slr_employee_candidate_id on slr_employee (cost=0.42..27.27 rows=1 width=4) (actual time=0.014..0.017 rows=3 loops=1)

  • Index Cond: (candidate_id = 31)
  • Filter: (ent_id = 1,500)
4. 0.768 0.768 ↓ 1.8 622 3

Index Scan using slr_in_out_charges_employee_id on slr_in_out_charges (cost=0.43..511.94 rows=354 width=8) (actual time=0.007..0.256 rows=622 loops=3)

  • Index Cond: (employee_id = slr_employee.id)
5. 5.598 5.598 ↓ 0.0 0 1,866

Index Scan using slr_taxes_reestr_charge_id on slr_taxes_reestr (cost=0.56..205.92 rows=1 width=173) (actual time=0.003..0.003 rows=0 loops=1,866)

  • Index Cond: (charge_id = slr_in_out_charges.id)
  • Filter: ((period_date >= '2020-05-01'::date) AND (period_date <= '2020-07-30'::date) AND (ent_id = 1,500) AND (tax_id = ANY ('{7,1,2,3,4,5,8,9,10,11,12,13,14,15}'::integer[])))
  • Rows Removed by Filter: 2