explain.depesz.com

PostgreSQL's explain analyze made readable

Result: ipYB

Settings
# exclusive inclusive rows x rows loops node
1. 0.023 375.713 ↑ 25.0 8 1

Sort (cost=851.11..851.61 rows=200 width=11) (actual time=375.711..375.713 rows=8 loops=1)

  • Sort Key: (('{BENCL1,BENCL2,BENCL3,BENCL4,BENCL5,BENCL6,BENCL7,BENCL8}'::text[])[i.i])
  • Sort Method: quicksort Memory: 25kB
  • Buffers: shared hit=209,145
2. 0.170 375.690 ↑ 25.0 8 1

HashAggregate (cost=841.47..843.47 rows=200 width=11) (actual time=375.689..375.690 rows=8 loops=1)

  • Group Key: ('{BENCL1,BENCL2,BENCL3,BENCL4,BENCL5,BENCL6,BENCL7,BENCL8}'::text[])[i.i]
  • Buffers: shared hit=209,145
3. 0.214 375.520 ↑ 3.0 329 1

Hash Left Join (cost=822.67..836.47 rows=1,000 width=11) (actual time=375.315..375.520 rows=329 loops=1)

  • Hash Cond: (('{BENCL1,BENCL2,BENCL3,BENCL4,BENCL5,BENCL6,BENCL7,BENCL8}'::text[])[i.i] = (i_1.location_id)::text)
  • Buffers: shared hit=209,145
4. 0.041 0.041 ↑ 125.0 8 1

Function Scan on generate_series i (cost=0.00..10.00 rows=1,000 width=4) (actual time=0.038..0.041 rows=8 loops=1)

5. 0.235 375.265 ↓ 326.0 326 1

Hash (cost=822.65..822.65 rows=1 width=7) (actual time=375.265..375.265 rows=326 loops=1)

  • Buckets: 1,024 Batches: 1 Memory Usage: 21kB
  • Buffers: shared hit=209,145
6. 0.815 375.030 ↓ 326.0 326 1

Nested Loop Left Join (cost=8.06..822.65 rows=1 width=7) (actual time=74.108..375.030 rows=326 loops=1)

  • Filter: (pscg.is_same_day_boning = COALESCE(al.is_same_day_boning, 'N'::bpchar))
  • Buffers: shared hit=209,145
7. 23.359 372.585 ↓ 326.0 326 1

Nested Loop (cost=7.64..822.20 rows=1 width=22) (actual time=74.086..372.585 rows=326 loops=1)

  • Join Filter: ((i_1.create_date = cs.carcase_kill_date) AND ((i_1.create_location_id)::text = (cs.carcase_kill_location)::text) AND (i_1.carcase_number = cs.carcase_number) AND (i_1.carcase_side_number = cs.carcase_side_number) AND ((pscg.sort_group_id)::text = (cs.sort_group_id)::text))
  • Rows Removed by Join Filter: 16,546
  • Buffers: shared hit=207,841
8. 52.196 307.046 ↓ 8,436.0 8,436 1

Nested Loop (cost=7.21..821.54 rows=1 width=65) (actual time=74.052..307.046 rows=8,436 loops=1)

  • Buffers: shared hit=173,713
9. 45.925 89.709 ↓ 382.3 55,047 1

Nested Loop (cost=6.78..149.69 rows=144 width=37) (actual time=0.377..89.709 rows=55,047 loops=1)

  • Buffers: shared hit=2,446
10. 0.054 0.260 ↓ 39.0 39 1

Nested Loop (cost=6.49..20.05 rows=1 width=11) (actual time=0.146..0.260 rows=39 loops=1)

  • Buffers: shared hit=16
11. 0.007 0.138 ↑ 1.0 1 1

Nested Loop (cost=1.90..4.57 rows=1 width=4) (actual time=0.112..0.138 rows=1 loops=1)

  • Buffers: shared hit=4
12. 0.046 0.115 ↑ 1.0 1 1

Hash Join (cost=1.75..3.57 rows=1 width=8) (actual time=0.092..0.115 rows=1 loops=1)

  • Hash Cond: (pss.uid = psmg.production_schedule_spec_uid)
  • Buffers: shared hit=2
13. 0.042 0.042 ↓ 1.2 68 1

Seq Scan on production_schedule_spec pss (cost=0.00..1.59 rows=59 width=8) (actual time=0.014..0.042 rows=68 loops=1)

  • Buffers: shared hit=1
14. 0.005 0.027 ↑ 1.0 1 1

Hash (cost=1.74..1.74 rows=1 width=8) (actual time=0.027..0.027 rows=1 loops=1)

  • Buckets: 1,024 Batches: 1 Memory Usage: 9kB
  • Buffers: shared hit=1
15. 0.022 0.022 ↑ 1.0 1 1

Seq Scan on production_schedule_marshalling_group psmg (cost=0.00..1.74 rows=1 width=8) (actual time=0.010..0.022 rows=1 loops=1)

  • Filter: (uid = 9,910)
  • Rows Removed by Filter: 69
  • Buffers: shared hit=1
16. 0.016 0.016 ↑ 1.0 1 1

Index Scan using production_schedule_pkey on production_schedule ps (cost=0.15..0.99 rows=1 width=4) (actual time=0.015..0.016 rows=1 loops=1)

  • Index Cond: (uid = pss.production_schedule_uid)
  • Filter: (is_active = 'Y'::bpchar)
  • Buffers: shared hit=2
17. 0.048 0.068 ↑ 1.0 39 1

Bitmap Heap Scan on production_schedule_carcase_group pscg (cost=4.59..15.09 rows=40 width=15) (actual time=0.028..0.068 rows=39 loops=1)

  • Recheck Cond: (production_schedule_marshalling_group_uid = 9,910)
  • Heap Blocks: exact=9
  • Buffers: shared hit=12
18. 0.020 0.020 ↑ 1.0 39 1

Bitmap Index Scan on pscg_mayhave_production_schedule_marshalling_group_fkey_idx (cost=0.00..4.58 rows=40 width=0) (actual time=0.020..0.020 rows=39 loops=1)

  • Index Cond: (production_schedule_marshalling_group_uid = 9,910)
  • Buffers: shared hit=3
19. 43.524 43.524 ↓ 2.2 1,411 39

Index Scan using inventory_ukey on inventory i_1 (cost=0.29..123.29 rows=635 width=26) (actual time=0.003..1.116 rows=1,411 loops=39)

  • Index Cond: (create_date = pscg.kill_date)
  • Filter: (status = 'A'::bpchar)
  • Rows Removed by Filter: 3
  • Buffers: shared hit=2,430
20. 165.141 165.141 ↓ 0.0 0 55,047

Index Scan using carcase_pkey on carcase c (cost=0.43..4.66 rows=1 width=28) (actual time=0.003..0.003 rows=0 loops=55,047)

  • Index Cond: ((kill_date = i_1.create_date) AND ((kill_location)::text = (i_1.create_location_id)::text) AND (number = i_1.carcase_number))
  • Buffers: shared hit=171,267
21. 42.180 42.180 ↓ 2.0 2 8,436

Index Scan using idx_cs_carcase on carcase_side cs (cost=0.43..0.63 rows=1 width=24) (actual time=0.004..0.005 rows=2 loops=8,436)

  • Index Cond: ((carcase_kill_date = c.kill_date) AND ((carcase_kill_location)::text = (c.kill_location)::text) AND (carcase_number = c.number))
  • Buffers: shared hit=34,128
22. 1.630 1.630 ↑ 1.0 1 326

Index Scan using advice_line_pkey on advice_line al (cost=0.42..0.44 rows=1 width=21) (actual time=0.004..0.005 rows=1 loops=326)

  • Index Cond: ((advice_number = c.advice_number) AND ((advice_season)::text = (c.advice_season)::text) AND (line = c.advice_line_line))
  • Buffers: shared hit=1,304
Planning time : 72.649 ms
Execution time : 376.053 ms