explain.depesz.com

PostgreSQL's explain analyze made readable

Result: miiw : New One

Settings
# exclusive inclusive rows x rows loops node
1. 6.125 1,264.790 ↓ 5.3 3,638 1

Nested Loop (cost=7,898.88..327,287.48 rows=683 width=46) (actual time=252.882..1,264.790 rows=3,638 loops=1)

2. 7.165 1,240.445 ↓ 5.1 3,644 1

Nested Loop (cost=7,898.45..325,715.69 rows=709 width=45) (actual time=252.871..1,240.445 rows=3,644 loops=1)

  • Join Filter: (lls.loan_id = ls.loan_id)
3. 94.260 1,215.060 ↓ 2.0 3,644 1

Nested Loop (cost=7,898.02..321,590.55 rows=1,819 width=49) (actual time=252.845..1,215.060 rows=3,644 loops=1)

4. 377.064 701.996 ↓ 1.0 104,701 1

Hash Join (cost=7,897.59..31,148.67 rows=104,700 width=45) (actual time=139.301..701.996 rows=104,701 loops=1)

  • Hash Cond: (ll.product_key = pp.product_key)
5. 191.598 191.598 ↓ 1.0 478,510 1

Seq Scan on loan_loan ll (cost=0.00..13,985.15 rows=478,115 width=23) (actual time=0.004..191.598 rows=478,510 loops=1)

6. 62.192 133.334 ↑ 1.0 104,702 1

Hash (cost=5,760.48..5,760.48 rows=105,209 width=37) (actual time=133.334..133.334 rows=104,702 loops=1)

  • Buckets: 65536 Batches: 4 Memory Usage: 2255kB
7. 71.142 71.142 ↑ 1.0 104,702 1

Seq Scan on party_payment_preference pp (cost=0.00..5,760.48 rows=105,209 width=37) (actual time=0.004..71.142 rows=104,702 loops=1)

  • Filter: (recurring_enabled AND (product_key IS NOT NULL))
  • Rows Removed by Filter: 41427
8. 418.804 418.804 ↓ 0.0 0 104,701

Index Scan using loan_loan_summary_loan_id_uniq on loan_loan_summary lls (cost=0.43..2.76 rows=1 width=4) (actual time=0.004..0.004 rows=0 loops=104,701)

  • Index Cond: (loan_id = ll.id)
  • Filter: ((next_payment_due IS NOT NULL) AND (next_payment_due_date = '2019-11-10 00:00:00'::timestamp without time zone))
  • Rows Removed by Filter: 1
9. 18.220 18.220 ↑ 1.0 1 3,644

Index Scan using loan_loan_summary_status_loan_id_key on loan_loan_summary_status ls (cost=0.43..2.26 rows=1 width=16) (actual time=0.005..0.005 rows=1 loops=3,644)

  • Index Cond: (loan_id = ll.id)
  • Filter: ((paid_off_date IS NULL) OR (paid_off_date >= ('now'::cstring)::date) OR (last_event_date >= ('now'::cstring)::date))
10. 18.220 18.220 ↑ 1.0 1 3,644

Index Scan using party_payment_mean_pkey on party_payment_mean pm (cost=0.42..2.21 rows=1 width=5) (actual time=0.005..0.005 rows=1 loops=3,644)

  • Index Cond: (id = pp.recurring_payment_mean_id)
  • Filter: ((disabled IS NULL) OR (NOT disabled))
  • Rows Removed by Filter: 0
Planning time : 1.159 ms
Execution time : 1,266.214 ms