explain.depesz.com

PostgreSQL's explain analyze made readable

Result: sbWp : limit80

Settings
# exclusive inclusive rows x rows loops node
1. 0.021 18,454.957 ↑ 1.0 80 1

Limit (cost=2,464,005.39..2,464,014.97 rows=80 width=30) (actual time=18,398.814..18,454.957 rows=80 loops=1)

2. 0.000 18,454.936 ↑ 191,811.9 80 1

Gather Merge (cost=2,464,005.39..4,301,327.70 rows=15,344,952 width=30) (actual time=18,398.810..18,454.936 rows=80 loops=1)

  • Workers Planned: 4
  • Workers Launched: 4
3. 11,058.425 91,509.305 ↑ 4,807.3 798 5

Sort (cost=2,459,005.33..2,468,595.93 rows=3,836,238 width=30) (actual time=18,301.412..18,301.861 rows=798 loops=5)

  • Sort Key: stock_picking__location_id.parent_left, stock_picking.user_done, stock_picking__stock_journal_id.id, stock_picking.state
  • Sort Method: external merge Disk: 69816kB
4. 4,620.395 80,450.880 ↑ 1.3 3,038,608 5

Hash Left Join (cost=22.25..1,985,727.28 rows=3,836,238 width=30) (actual time=0.761..16,090.176 rows=3,038,608 loops=5)

  • Hash Cond: (stock_picking.stock_journal_id = stock_picking__stock_journal_id.id)
5. 75,829.010 75,830.305 ↑ 1.3 3,038,608 5

Hash Left Join (cost=19.81..1,974,987.87 rows=3,836,238 width=30) (actual time=0.705..15,166.061 rows=3,038,608 loops=5)

  • Hash Cond: (stock_picking.location_id = stock_picking__location_id.id)
  • -> Parallel Seq Scan on stock_picking (cost=0.00..1964893.58 rows=3836238 width=30) (actual time=0.272..14111.401 rows=3038608 lo
  • Filter: (((company_id IS NULL) OR (company_id = 1)) AND ((type)::text = 'internal'::text) AND (((name)::text = '9'::text) OR
  • Rows Removed by Filter: 8127964
6. 1.295 1.295 ↑ 1.0 347 5

Hash (cost=15.47..15.47 rows=347 width=8) (actual time=0.259..0.259 rows=347 loops=5)

  • Buckets: 1024 Batches: 1 Memory Usage: 22kB
  • -> Seq Scan on stock_location stock_picking__location_id (cost=0.00..15.47 rows=347 width=8) (actual time=0.020..0.195 rows
7. 0.180 0.180 ↑ 1.0 64 5

Hash (cost=1.64..1.64 rows=64 width=4) (actual time=0.036..0.036 rows=64 loops=5)

  • Buckets: 1024 Batches: 1 Memory Usage: 11kB
  • -> Seq Scan on stock_journal stock_picking__stock_journal_id (cost=0.00..1.64 rows=64 width=4) (actual time=0.018..0.024 rows=64
Planning time : 1.201 ms
Execution time : 18,479.766 ms