explain.depesz.com

PostgreSQL's explain analyze made readable

Result: i0eL

Settings
# exclusive inclusive rows x rows loops node
1. 0.001 2.352 ↓ 0.0 0 1

Nested Loop (cost=8,157.49..8,276.01 rows=1 width=1,976) (actual time=2.352..2.352 rows=0 loops=1)

2. 0.001 2.351 ↓ 0.0 0 1

Nested Loop (cost=8,157.07..8,274.34 rows=1 width=224) (actual time=2.351..2.351 rows=0 loops=1)

  • Join Filter: (creditnote.referencedinvoice_id = referencedinvoice.id)
3. 0.000 2.350 ↓ 0.0 0 1

Nested Loop Left Join (cost=8,156.64..8,266.13 rows=1 width=202) (actual time=2.350..2.350 rows=0 loops=1)

4. 0.000 2.350 ↓ 0.0 0 1

Nested Loop Left Join (cost=8,156.50..8,265.97 rows=1 width=206) (actual time=2.350..2.350 rows=0 loops=1)

5. 0.001 2.350 ↓ 0.0 0 1

Nested Loop Left Join (cost=8,156.07..8,257.71 rows=1 width=206) (actual time=2.349..2.350 rows=0 loops=1)

6. 0.000 2.349 ↓ 0.0 0 1

Nested Loop Left Join (cost=8,155.79..8,256.91 rows=1 width=196) (actual time=2.349..2.349 rows=0 loops=1)

7. 0.012 2.349 ↓ 0.0 0 1

Nested Loop (cost=8,155.52..8,250.60 rows=1 width=186) (actual time=2.348..2.349 rows=0 loops=1)

  • Join Filter: (creditnote.originatordivision_id = lineitemdivision.id)
8. 0.013 0.013 ↑ 1.0 14 1

Index Scan using divisionbase_buyer_idx on divisionbase lineitemdivision (cost=0.14..12.35 rows=14 width=28) (actual time=0.007..0.013 rows=14 loops=1)

9. 0.000 2.324 ↓ 0.0 0 14

Materialize (cost=8,155.38..8,238.05 rows=1 width=174) (actual time=0.166..0.166 rows=0 loops=14)

10. 0.295 2.324 ↓ 0.0 0 1

Hash Join (cost=8,155.38..8,238.05 rows=1 width=174) (actual time=2.323..2.324 rows=0 loops=1)

  • Hash Cond: (creditnote.referencedinvoice_id = financedinvoiceeps.invoice_id)
11. 0.611 0.611 ↑ 1.0 1,411 1

Seq Scan on suppliercreditnote creditnote (cost=0.00..78.96 rows=1,411 width=158) (actual time=0.009..0.611 rows=1,411 loops=1)

  • Filter: (nettingbundle_id IS NULL)
  • Rows Removed by Filter: 685
12. 0.545 1.418 ↑ 1.4 1,585 1

Hash (cost=8,127.37..8,127.37 rows=2,241 width=16) (actual time=1.418..1.418 rows=1,585 loops=1)

  • Buckets: 4096 Batches: 1 Memory Usage: 107kB
13. 0.873 0.873 ↑ 1.4 1,585 1

Index Scan using earlypaymentsettlement_creationdate_idx on earlypaymentsettlement financedinvoiceeps (cost=0.43..8,127.37 rows=2,241 width=16) (actual time=0.015..0.873 rows=1,585 loops=1)

  • Index Cond: (creationdate = '2018-10-11'::date)
14. 0.000 0.000 ↓ 0.0 0

Index Scan using corporatebase_pkey on corporatebase lineitembuyer (cost=0.28..6.29 rows=1 width=26) (never executed)

  • Index Cond: (id = lineitemdivision.buyer_id)
15. 0.000 0.000 ↓ 0.0 0

Index Scan using corporatebase_pkey on corporatebase lineitemsupplier (cost=0.28..0.81 rows=1 width=26) (never executed)

  • Index Cond: (id = creditnote.supplier_id)
16. 0.000 0.000 ↓ 0.0 0

Index Scan using arpimportbatch_pkey on arpimportbatch lineitemimportbatch (cost=0.43..8.25 rows=1 width=16) (never executed)

  • Index Cond: (creditnote.importbatch_id = id)
17. 0.000 0.000 ↓ 0.0 0

Index Scan using crxcurrency_pkey on crxcurrency lineitemcurrency (cost=0.13..0.16 rows=1 width=12) (never executed)

  • Index Cond: (creditnote.currency_id = id)
18. 0.000 0.000 ↓ 0.0 0

Index Scan using supplierinvoice_pkey on supplierinvoice referencedinvoice (cost=0.43..8.20 rows=1 width=38) (never executed)

  • Index Cond: (id = financedinvoiceeps.invoice_id)
19. 0.000 0.000 ↓ 0.0 0

Index Only Scan using ddearlypaymentsettlement_pkey on ddearlypaymentsettlement financedinvoiceddeps (cost=0.42..1.67 rows=1 width=8) (never executed)

  • Index Cond: (id = financedinvoiceeps.id)
  • Heap Fetches: 0
Planning time : 4.585 ms
Execution time : 2.516 ms