explain.depesz.com

PostgreSQL's explain analyze made readable

Result: qzZlM

Settings
# exclusive inclusive rows x rows loops node
1. 11.077 1,372.799 ↑ 119.3 1,831 1

Gather (cost=278,308.13..310,758.12 rows=218,482 width=3,113) (actual time=1,358.730..1,372.799 rows=1,831 loops=1)

  • Workers Planned: 4
  • Workers Launched: 4
2. 3.053 1,361.722 ↑ 149.2 366 5 / 5

Parallel Hash Join (cost=277,308.13..287,909.92 rows=54,620 width=3,113) (actual time=1,350.412..1,361.722 rows=366 loops=5)

  • Hash Cond: (surplusinvoice.id = financedinvoiceeps.invoice_id)
3. 0.543 12.266 ↑ 4,487.4 366 5 / 5

Merge Join (cost=3,476.74..7,646.52 rows=1,642,376 width=1,341) (actual time=1.802..12.266 rows=366 loops=5)

  • Merge Cond: (invoice.nettingbundle_id = lineitemnettingbundle.id)
  • Join Filter: (invoice.id <> lineitemnettingbundle.surplus_id)
  • Rows Removed by Join Filter: 82
4. 0.803 9.901 ↑ 3,657.9 449 5 / 5

Nested Loop Left Join (cost=1.69..12,489,257.95 rows=1,642,376 width=1,333) (actual time=0.090..9.901 rows=449 loops=5)

5. 0.533 8.649 ↑ 3,657.9 449 5 / 5

Nested Loop Left Join (cost=1.41..2,156,481.18 rows=1,642,376 width=1,323) (actual time=0.080..8.649 rows=449 loops=5)

6. 1.357 6.768 ↑ 3,657.9 449 5 / 5

Nested Loop Left Join (cost=1.28..1,912,761.67 rows=1,642,376 width=815) (actual time=0.070..6.768 rows=449 loops=5)

7. 0.845 4.513 ↑ 3,657.9 449 5 / 5

Nested Loop Left Join (cost=0.84..1,095,663.47 rows=1,642,376 width=815) (actual time=0.053..4.513 rows=449 loops=5)

8. 1.640 3.219 ↑ 3,657.9 449 5 / 5

Nested Loop (cost=0.57..610,999.04 rows=1,642,376 width=805) (actual time=0.040..3.219 rows=449 loops=5)

9. 0.231 0.231 ↑ 3,657.9 449 5 / 5

Parallel Index Scan using supplierinvoice_nettingbundle_idx on supplierinvoice invoice (cost=0.43..362,156.71 rows=1,642,376 width=199) (actual time=0.019..0.231 rows=449 loops=5)

10. 1.348 1.348 ↑ 1.0 1 2,246 / 5

Index Scan using divisionbase_pkey on divisionbase lineitemdivision (cost=0.14..0.15 rows=1 width=622) (actual time=0.003..0.003 rows=1 loops=2,246)

  • Index Cond: (id = invoice.originatordivision_id)
11. 0.449 0.449 ↑ 1.0 1 2,246 / 5

Index Scan using corporatebase_pkey on corporatebase lineitemsupplier (cost=0.28..0.30 rows=1 width=26) (actual time=0.001..0.001 rows=1 loops=2,246)

  • Index Cond: (id = invoice.supplier_id)
12. 0.898 0.898 ↑ 1.0 1 2,246 / 5

Index Scan using arpimportbatch_pkey on arpimportbatch lineitemimportbatch (cost=0.43..0.50 rows=1 width=16) (actual time=0.002..0.002 rows=1 loops=2,246)

  • Index Cond: (invoice.importbatch_id = id)
13. 1.348 1.348 ↑ 1.0 1 2,246 / 5

Index Scan using crxcurrency_pkey on crxcurrency lineitemcurrency (cost=0.13..0.15 rows=1 width=524) (actual time=0.003..0.003 rows=1 loops=2,246)

  • Index Cond: (invoice.currency_id = id)
14. 0.449 0.449 ↑ 1.0 1 2,246 / 5

Index Scan using corporatebase_pkey on corporatebase lineitembuyer (cost=0.28..6.29 rows=1 width=26) (actual time=0.001..0.001 rows=1 loops=2,246)

  • Index Cond: (id = lineitemdivision.buyer_id)
15. 0.376 1.822 ↓ 1.6 675 5 / 5

Sort (cost=3,474.39..3,475.42 rows=410 width=24) (actual time=1.633..1.822 rows=675 loops=5)

  • Sort Key: lineitemnettingbundle.id
  • Sort Method: quicksort Memory: 57kB
  • Worker 0: Sort Method: quicksort Memory: 57kB
  • Worker 1: Sort Method: quicksort Memory: 57kB
  • Worker 2: Sort Method: quicksort Memory: 57kB
  • Worker 3: Sort Method: quicksort Memory: 57kB
16. 0.495 1.446 ↑ 1.0 410 5 / 5

Nested Loop (cost=0.43..3,456.60 rows=410 width=24) (actual time=0.029..1.446 rows=410 loops=5)

17. 0.131 0.131 ↑ 1.0 410 5 / 5

Seq Scan on nettingbundle lineitemnettingbundle (cost=0.00..8.10 rows=410 width=16) (actual time=0.012..0.131 rows=410 loops=5)

18. 0.820 0.820 ↑ 1.0 1 2,050 / 5

Index Only Scan using supplierinvoice_pkey on supplierinvoice surplusinvoice (cost=0.43..8.41 rows=1 width=8) (actual time=0.002..0.002 rows=1 loops=2,050)

  • Index Cond: (id = lineitemnettingbundle.surplus_id)
  • Heap Fetches: 2050
19. 7.296 1,346.403 ↑ 5.1 10,652 5 / 5

Parallel Hash (cost=273,148.64..273,148.64 rows=54,620 width=8) (actual time=1,346.403..1,346.403 rows=10,652 loops=5)

  • Buckets: 262144 Batches: 1 Memory Usage: 4224kB
20. 582.891 1,339.107 ↑ 5.1 10,652 5 / 5

Parallel Hash Join (cost=4,787.81..273,148.64 rows=54,620 width=8) (actual time=1,302.074..1,339.107 rows=10,652 loops=5)

  • Hash Cond: (financedinvoiceeps.id = financedinvoiceddeps.id)
21. 700.383 700.383 ↑ 1.2 1,083,659 5 / 5

Parallel Seq Scan on earlypaymentsettlement financedinvoiceeps (cost=0.00..264,805.63 rows=1,354,362 width=16) (actual time=0.006..700.383 rows=1,083,659 loops=5)

  • Filter: (creationdate >= '2019-01-01'::date)
  • Rows Removed by Filter: 189854
22. 31.501 55.833 ↑ 2.9 51,360 5 / 5

Parallel Hash (cost=2,899.58..2,899.58 rows=151,058 width=8) (actual time=55.833..55.833 rows=51,360 loops=5)

  • Buckets: 262144 Batches: 1 Memory Usage: 12192kB
23. 24.332 24.332 ↑ 2.9 51,360 5 / 5

Parallel Seq Scan on ddearlypaymentsettlement financedinvoiceddeps (cost=0.00..2,899.58 rows=151,058 width=8) (actual time=0.008..24.332 rows=51,360 loops=5)

Planning time : 4.227 ms
Execution time : 1,373.542 ms