explain.depesz.com

PostgreSQL's explain analyze made readable

Result: iaZp

Settings
# exclusive inclusive rows x rows loops node
1. 1.544 17.662 ↓ 3.0 685 1

Nested Loop Left Join (cost=126.25..7,453.34 rows=225 width=2,686) (actual time=2.461..17.662 rows=685 loops=1)

2. 0.494 15.433 ↓ 3.0 685 1

Hash Left Join (cost=126.12..5,580.76 rows=225 width=387) (actual time=2.441..15.433 rows=685 loops=1)

  • Hash Cond: (scn.currency_id = c.id)
3. 0.674 14.926 ↓ 3.0 685 1

Nested Loop Left Join (cost=124.98..5,578.61 rows=225 width=391) (actual time=2.415..14.926 rows=685 loops=1)

4. 0.493 9.457 ↓ 3.0 685 1

Hash Left Join (cost=124.55..3,742.63 rows=225 width=391) (actual time=1.430..9.457 rows=685 loops=1)

  • Hash Cond: (fi_eps.earlypaymentadvice_id = fi_eps_epa.id)
5. 0.803 8.308 ↓ 3.0 685 1

Nested Loop Left Join (cost=92.29..3,709.77 rows=225 width=377) (actual time=0.761..8.308 rows=685 loops=1)

6. 1.096 7.505 ↓ 3.0 685 1

Nested Loop Left Join (cost=92.15..3,673.21 rows=225 width=377) (actual time=0.756..7.505 rows=685 loops=1)

7. 0.500 5.724 ↓ 3.0 685 1

Hash Left Join (cost=91.87..3,529.12 rows=225 width=367) (actual time=0.745..5.724 rows=685 loops=1)

  • Hash Cond: (fi_si.originatordivision_id = od_db.id)
8. 0.754 4.563 ↓ 3.0 685 1

Nested Loop Left Join (cost=2.42..3,436.57 rows=225 width=345) (actual time=0.071..4.563 rows=685 loops=1)

9. 0.662 3.809 ↓ 3.0 685 1

Nested Loop (cost=1.99..1,580.78 rows=225 width=315) (actual time=0.064..3.809 rows=685 loops=1)

10. 0.194 2.631 ↓ 9.1 172 1

Nested Loop Left Join (cost=1.71..1,544.21 rows=19 width=172) (actual time=0.054..2.631 rows=172 loops=1)

11. 0.188 2.093 ↓ 9.1 172 1

Nested Loop (cost=1.29..1,535.39 rows=19 width=56) (actual time=0.045..2.093 rows=172 loops=1)

  • Join Filter: (nb.surplus_id = fi_si.id)
12. 0.099 1.389 ↓ 9.1 172 1

Nested Loop (cost=0.86..1,522.97 rows=19 width=56) (actual time=0.033..1.389 rows=172 loops=1)

13. 0.204 0.774 ↓ 1.2 172 1

Nested Loop (cost=0.43..1,457.55 rows=146 width=56) (actual time=0.024..0.774 rows=172 loops=1)

14. 0.054 0.054 ↑ 1.0 172 1

Seq Scan on nettingbundle nb (cost=0.00..3.72 rows=172 width=16) (actual time=0.007..0.054 rows=172 loops=1)

15. 0.516 0.516 ↑ 1.0 1 172

Index Scan using earlypaymentsettlement_invoice_idx on earlypaymentsettlement fi_eps (cost=0.43..8.45 rows=1 width=40) (actual time=0.003..0.003 rows=1 loops=172)

  • Index Cond: (invoice_id = nb.surplus_id)
  • Filter: (creationdate >= '2019-01-01'::date)
16. 0.516 0.516 ↑ 1.0 1 172

Index Scan using apfearlypaymentsettlement_pkey on apfearlypaymentsettlement fi_ps_apfeps (cost=0.42..0.45 rows=1 width=24) (actual time=0.003..0.003 rows=1 loops=172)

  • Index Cond: (id = fi_eps.id)
17. 0.516 0.516 ↑ 1.0 1 172

Index Scan using supplierinvoice_pkey on supplierinvoice fi_si (cost=0.43..0.64 rows=1 width=24) (actual time=0.003..0.003 rows=1 loops=172)

  • Index Cond: (id = fi_eps.invoice_id)
18. 0.344 0.344 ↑ 1.0 1 172

Index Scan using apffinancingcontext_pkey on apffinancingcontext fi_ps_apffc_fc_afc (cost=0.42..0.46 rows=1 width=132) (actual time=0.002..0.002 rows=1 loops=172)

  • Index Cond: (id = fi_ps_apfeps.financingcontext_id)
19. 0.516 0.516 ↑ 1.0 4 172

Index Scan using suppliercreditnote_nettingbundle_idx on suppliercreditnote scn (cost=0.28..1.88 rows=4 width=151) (actual time=0.002..0.003 rows=4 loops=172)

  • Index Cond: (nettingbundle_id = nb.id)
20. 0.000 0.000 ↓ 0.0 0 685

Index Scan using supplierinvoice_pkey on supplierinvoice ref_si (cost=0.43..8.21 rows=1 width=38) (actual time=0.000..0.000 rows=0 loops=685)

  • Index Cond: (id = scn.referencedinvoice_id)
21. 0.012 0.661 ↑ 1.0 14 1

Hash (cost=89.28..89.28 rows=14 width=38) (actual time=0.661..0.661 rows=14 loops=1)

  • Buckets: 1,024 Batches: 1 Memory Usage: 9kB
22. 0.027 0.649 ↑ 1.0 14 1

Nested Loop Left Join (cost=0.28..89.28 rows=14 width=38) (actual time=0.041..0.649 rows=14 loops=1)

23. 0.006 0.006 ↑ 1.0 14 1

Seq Scan on divisionbase od_db (cost=0.00..1.14 rows=14 width=28) (actual time=0.002..0.006 rows=14 loops=1)

24. 0.616 0.616 ↑ 1.0 1 14

Index Scan using corporatebase_pkey on corporatebase od_c_cb (cost=0.28..6.29 rows=1 width=26) (actual time=0.044..0.044 rows=1 loops=14)

  • Index Cond: (id = od_db.buyer_id)
25. 0.685 0.685 ↑ 1.0 1 685

Index Scan using corporatebase_pkey on corporatebase s_cb (cost=0.28..0.64 rows=1 width=26) (actual time=0.001..0.001 rows=1 loops=685)

  • Index Cond: (id = scn.supplier_id)
26. 0.000 0.000 ↓ 0.0 0 685

Index Scan using bankpaymenttransaction_mapping_idx on bankpaymenttransaction bpt (cost=0.14..0.15 rows=1 width=16) (actual time=0.000..0.000 rows=0 loops=685)

  • Index Cond: (mapping_id = fi_eps.earlypaymentmapping_id)
27. 0.365 0.656 ↑ 1.0 945 1

Hash (cost=20.45..20.45 rows=945 width=30) (actual time=0.656..0.656 rows=945 loops=1)

  • Buckets: 1,024 Batches: 1 Memory Usage: 68kB
28. 0.291 0.291 ↑ 1.0 945 1

Seq Scan on earlypaymentadvice fi_eps_epa (cost=0.00..20.45 rows=945 width=30) (actual time=0.004..0.291 rows=945 loops=1)

29. 4.795 4.795 ↑ 1.0 1 685

Index Scan using arpimportbatch_pkey on arpimportbatch ib (cost=0.43..8.16 rows=1 width=16) (actual time=0.007..0.007 rows=1 loops=685)

  • Index Cond: (scn.importbatch_id = id)
30. 0.007 0.013 ↑ 1.0 6 1

Hash (cost=1.06..1.06 rows=6 width=12) (actual time=0.013..0.013 rows=6 loops=1)

  • Buckets: 1,024 Batches: 1 Memory Usage: 9kB
31. 0.006 0.006 ↑ 1.0 6 1

Seq Scan on crxcurrency c (cost=0.00..1.06 rows=6 width=12) (actual time=0.004..0.006 rows=6 loops=1)

32. 0.000 0.000 ↓ 0.0 0 685

Index Scan using invoicepaymentadvice_pkey on invoicepaymentadvice fi_ipa (cost=0.14..0.15 rows=1 width=1,052) (actual time=0.000..0.000 rows=0 loops=685)

  • Index Cond: (fi_si.paymentadvice_id = id)
33.          

SubPlan (for Nested Loop Left Join)

34. 0.685 0.685 ↑ 1.0 1 685

Aggregate (cost=8.15..8.16 rows=1 width=8) (actual time=0.001..0.001 rows=1 loops=685)

35. 0.000 0.000 ↓ 0.0 0 685

Index Scan using bankpaymenttransaction_mapping_idx on bankpaymenttransaction bpt_1 (cost=0.14..8.15 rows=1 width=8) (actual time=0.000..0.000 rows=0 loops=685)

  • Index Cond: (mapping_id = fi_eps.maturitypaymentmapping_id)
Planning time : 8.592 ms
Execution time : 18.061 ms