explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 43Ix

Settings
# exclusive inclusive rows x rows loops node
1. 10.621 14.617 ↑ 380.1 402 1

Gather (cost=3,008.77..1,286,915.04 rows=152,787 width=2,716) (actual time=10.311..14.617 rows=402 loops=1)

  • Workers Planned: 4
  • Workers Launched: 4
2. 0.056 3.594 ↑ 477.5 80 5 / 5

Hash Left Join (cost=2,008.77..21,984.58 rows=38,197 width=1,433) (actual time=2.882..3.594 rows=80 loops=5)

  • Hash Cond: (fi_eps.earlypaymentmapping_id = fi_bpt.mapping_id)
3. 0.057 3.537 ↑ 477.5 80 5 / 5

Hash Left Join (cost=1,998.55..21,831.11 rows=38,197 width=1,433) (actual time=2.877..3.537 rows=80 loops=5)

  • Hash Cond: (fi_si.paymentadvice_id = fi_ipa.id)
4. 0.063 3.478 ↑ 477.5 80 5 / 5

Hash Left Join (cost=1,988.32..21,720.62 rows=38,197 width=389) (actual time=2.873..3.478 rows=80 loops=5)

  • Hash Cond: (fi_eps.earlypaymentadvice_id = fi_eps_epa.id)
5. 0.097 3.159 ↑ 477.5 80 5 / 5

Nested Loop Left Join (cost=1,956.06..21,588.09 rows=38,197 width=375) (actual time=2.613..3.159 rows=80 loops=5)

6. 0.059 2.821 ↑ 477.5 80 5 / 5

Hash Left Join (cost=1,955.63..2,584.80 rows=38,197 width=375) (actual time=2.496..2.821 rows=80 loops=5)

  • Hash Cond: (si.currency_id = c.id)
7. 0.058 2.758 ↑ 477.5 80 5 / 5

Hash Left Join (cost=1,954.49..2,412.57 rows=38,197 width=379) (actual time=2.489..2.758 rows=80 loops=5)

  • Hash Cond: (si.supplier_id = s_cb.id)
8. 0.069 2.161 ↑ 477.5 80 5 / 5

Hash Left Join (cost=1,743.37..2,100.93 rows=38,197 width=369) (actual time=1.946..2.161 rows=80 loops=5)

  • Hash Cond: (od_db.buyer_id = od_c_cb.id)
9. 0.255 1.483 ↑ 477.5 80 5 / 5

Merge Join (cost=1,532.24..1,789.28 rows=38,197 width=359) (actual time=1.322..1.483 rows=80 loops=5)

  • Merge Cond: (si.nettingbundle_id = nb.id)
10. 0.206 0.206 ↑ 3,116.6 527 5 / 5

Parallel Index Scan using supplierinvoice_nettingbundle_idx on supplierinvoice si (cost=0.43..784,438.39 rows=1,642,460 width=183) (actual time=0.008..0.206 rows=527 loops=5)

11. 0.044 1.022 ↓ 56.8 227 2 / 5

Sort (cost=1,531.81..1,531.82 rows=4 width=184) (actual time=2.499..2.554 rows=227 loops=2)

  • Sort Key: nb.id
  • Sort Method: quicksort Memory: 34kB
  • Worker 3: Sort Method: quicksort Memory: 34kB
12. 0.022 0.977 ↓ 16.8 67 2 / 5

Nested Loop Left Join (cost=1.71..1,531.77 rows=4 width=184) (actual time=1.078..2.443 rows=67 loops=2)

13. 0.117 0.902 ↓ 16.8 67 2 / 5

Nested Loop Left Join (cost=1.29..1,529.91 rows=4 width=68) (actual time=1.069..2.255 rows=67 loops=2)

  • Join Filter: (fi_si.originatordivision_id = od_db.id)
  • Rows Removed by Join Filter: 871
14. 0.030 0.704 ↓ 16.8 67 2 / 5

Nested Loop (cost=1.29..1,527.90 rows=4 width=56) (actual time=1.042..1.761 rows=67 loops=2)

15. 0.097 0.620 ↓ 16.8 67 2 / 5

Nested Loop (cost=0.86..1,525.34 rows=4 width=56) (actual time=1.033..1.551 rows=67 loops=2)

  • Join Filter: (fi_ps_apfeps.apfda_id = fi_ps_apfeps_t_apfda.id)
  • Rows Removed by Join Filter: 525
16. 0.066 0.455 ↓ 9.1 172 2 / 5

Nested Loop (cost=0.86..1,522.97 rows=19 width=64) (actual time=0.026..1.137 rows=172 loops=2)

17. 0.092 0.251 ↓ 1.2 172 2 / 5

Nested Loop (cost=0.43..1,457.55 rows=146 width=56) (actual time=0.018..0.628 rows=172 loops=2)

18. 0.022 0.022 ↑ 1.0 172 2 / 5

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

19. 0.138 0.138 ↑ 1.0 1 344 / 5

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

  • Index Cond: (invoice_id = nb.surplus_id)
  • Filter: (creationdate >= '2019-01-01'::date)
20. 0.138 0.138 ↑ 1.0 1 344 / 5

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

  • Index Cond: (id = fi_eps.id)
21. 0.066 0.069 ↑ 1.3 3 344 / 5

Materialize (cost=0.00..1.27 rows=4 width=8) (actual time=0.000..0.001 rows=3 loops=344)

22. 0.003 0.003 ↑ 1.0 4 2 / 5

Seq Scan on apfdebtoragreement fi_ps_apfeps_t_apfda (cost=0.00..1.25 rows=4 width=8) (actual time=0.005..0.007 rows=4 loops=2)

  • Filter: (buyer_id = 67002626)
  • Rows Removed by Filter: 16
23. 0.054 0.054 ↑ 1.0 1 134 / 5

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

  • Index Cond: (id = fi_eps.invoice_id)
24. 0.075 0.080 ↑ 1.0 14 134 / 5

Materialize (cost=0.00..1.21 rows=14 width=28) (actual time=0.000..0.003 rows=14 loops=134)

25. 0.005 0.005 ↑ 1.0 14 2 / 5

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

26. 0.054 0.054 ↑ 1.0 1 134 / 5

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=134)

  • Index Cond: (fi_ps_apfeps.financingcontext_id = id)
27. 0.238 0.609 ↑ 1.0 1,650 2 / 5

Hash (cost=190.50..190.50 rows=1,650 width=26) (actual time=1.521..1.522 rows=1,650 loops=2)

  • Buckets: 2048 Batches: 1 Memory Usage: 119kB
28. 0.370 0.370 ↑ 1.0 1,650 2 / 5

Seq Scan on corporatebase od_c_cb (cost=0.00..190.50 rows=1,650 width=26) (actual time=0.005..0.926 rows=1,650 loops=2)

29. 0.235 0.539 ↑ 1.0 1,650 2 / 5

Hash (cost=190.50..190.50 rows=1,650 width=26) (actual time=1.348..1.348 rows=1,650 loops=2)

  • Buckets: 2048 Batches: 1 Memory Usage: 119kB
30. 0.304 0.304 ↑ 1.0 1,650 2 / 5

Seq Scan on corporatebase s_cb (cost=0.00..190.50 rows=1,650 width=26) (actual time=0.002..0.760 rows=1,650 loops=2)

31. 0.002 0.004 ↑ 1.0 6 2 / 5

Hash (cost=1.06..1.06 rows=6 width=12) (actual time=0.010..0.011 rows=6 loops=2)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
32. 0.002 0.002 ↑ 1.0 6 2 / 5

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

33. 0.241 0.241 ↑ 1.0 1 402 / 5

Index Scan using arpimportbatch_pkey on arpimportbatch ib (cost=0.43..0.50 rows=1 width=16) (actual time=0.003..0.003 rows=1 loops=402)

  • Index Cond: (si.importbatch_id = id)
34. 0.132 0.256 ↑ 1.0 945 2 / 5

Hash (cost=20.45..20.45 rows=945 width=30) (actual time=0.640..0.641 rows=945 loops=2)

  • Buckets: 1024 Batches: 1 Memory Usage: 68kB
35. 0.124 0.124 ↑ 1.0 945 2 / 5

Seq Scan on earlypaymentadvice fi_eps_epa (cost=0.00..20.45 rows=945 width=30) (actual time=0.005..0.311 rows=945 loops=2)

36. 0.000 0.002 ↓ 0.0 0 2 / 5

Hash (cost=10.10..10.10 rows=10 width=1,052) (actual time=0.004..0.004 rows=0 loops=2)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
37. 0.001 0.001 ↓ 0.0 0 2 / 5

Seq Scan on invoicepaymentadvice fi_ipa (cost=0.00..10.10 rows=10 width=1,052) (actual time=0.003..0.003 rows=0 loops=2)

38. 0.000 0.001 ↓ 0.0 0 2 / 5

Hash (cost=10.10..10.10 rows=10 width=16) (actual time=0.003..0.003 rows=0 loops=2)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
39. 0.001 0.001 ↓ 0.0 0 2 / 5

Seq Scan on bankpaymenttransaction fi_bpt (cost=0.00..10.10 rows=10 width=16) (actual time=0.002..0.002 rows=0 loops=2)

40.          

SubPlan (for Gather)

41. 0.402 0.402 ↑ 1.0 1 402

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

42. 0.000 0.000 ↓ 0.0 0 402

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

  • Index Cond: (mapping_id = fi_eps.maturitypaymentmapping_id)
Planning time : 9.690 ms
Execution time : 14.951 ms