explain.depesz.com

PostgreSQL's explain analyze made readable

Result: OHsd

Settings
# exclusive inclusive rows x rows loops node
1. 397.919 4,132.636 ↑ 1.0 423,444 1

Hash Join (cost=52,733.67..255,840.06 rows=423,444 width=690) (actual time=623.161..4,132.636 rows=423,444 loops=1)

  • Hash Cond: (events.programs_id = programs.id)
  • Buffers: shared hit=983367 read=58652, temp read=15614 written=15584
2. 282.093 3,734.334 ↑ 1.0 423,444 1

Hash Join (cost=52,692.53..247,859.34 rows=423,444 width=530) (actual time=622.769..3,734.334 rows=423,444 loops=1)

  • Hash Cond: (claims_1.staffing_users_id = staffing_users.id)
  • Buffers: shared hit=983365 read=58628, temp read=15614 written=15584
3. 218.041 3,430.014 ↑ 1.0 423,444 1

Hash Join (cost=49,851.44..239,195.89 rows=423,444 width=530) (actual time=600.496..3,430.014 rows=423,444 loops=1)

  • Hash Cond: (claims_1.payroll_periods_id = payroll_periods.id)
  • Buffers: shared hit=983363 read=56734, temp read=15614 written=15584
4. 839.611 3,211.915 ↑ 1.0 423,444 1

Hash Left Join (cost=49,845.74..233,367.84 rows=423,444 width=522) (actual time=600.427..3,211.915 rows=423,444 loops=1)

  • Hash Cond: (claims_1.events_staffing_days_positions_id = events_staffing_days_positions.id)
  • Buffers: shared hit=983362 read=56732, temp read=15614 written=15584
5. 658.919 1,772.553 ↑ 1.0 423,444 1

Merge Join (cost=72.85..117,237.94 rows=423,444 width=518) (actual time=0.118..1,772.553 rows=423,444 loops=1)

  • Merge Cond: (claims_1.events_id = events.id)
  • Buffers: shared hit=983329 read=36063
6. 415.623 415.623 ↑ 1.0 423,444 1

Index Scan using claims_events_id_idx on claims claims_1 (cost=0.42..43,146.11 rows=423,444 width=466) (actual time=0.010..415.623 rows=423,444 loops=1)

  • Buffers: shared hit=363987 read=9383
7. 698.011 698.011 ↓ 1.2 1,230,104 1

Index Scan using events_pkey on events (cost=0.43..66,221.03 rows=1,058,835 width=56) (actual time=0.007..698.011 rows=1,230,104 loops=1)

  • Buffers: shared hit=619342 read=26680
8. 308.502 599.751 ↑ 1.0 1,100,884 1

Hash (cost=31,710.84..31,710.84 rows=1,100,884 width=8) (actual time=599.751..599.751 rows=1,100,884 loops=1)

  • Buckets: 131072 Batches: 16 Memory Usage: 3723kB
  • Buffers: shared hit=33 read=20669, temp written=3518
9. 291.249 291.249 ↑ 1.0 1,100,884 1

Seq Scan on events_staffing_days_positions (cost=0.00..31,710.84 rows=1,100,884 width=8) (actual time=0.008..291.249 rows=1,100,884 loops=1)

  • Buffers: shared hit=33 read=20669
10. 0.026 0.058 ↑ 1.0 120 1

Hash (cost=4.20..4.20 rows=120 width=12) (actual time=0.058..0.058 rows=120 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 14kB
  • Buffers: shared hit=1 read=2
11. 0.032 0.032 ↑ 1.0 120 1

Seq Scan on payroll_periods (cost=0.00..4.20 rows=120 width=12) (actual time=0.007..0.032 rows=120 loops=1)

  • Buffers: shared hit=1 read=2
12. 10.763 22.227 ↑ 1.0 42,004 1

Hash (cost=2,316.04..2,316.04 rows=42,004 width=4) (actual time=22.227..22.227 rows=42,004 loops=1)

  • Buckets: 65536 Batches: 1 Memory Usage: 1989kB
  • Buffers: shared hit=2 read=1894
13. 11.464 11.464 ↑ 1.0 42,004 1

Seq Scan on staffing_users (cost=0.00..2,316.04 rows=42,004 width=4) (actual time=0.005..11.464 rows=42,004 loops=1)

  • Buffers: shared hit=2 read=1894
14. 0.154 0.383 ↑ 1.0 673 1

Hash (cost=32.73..32.73 rows=673 width=36) (actual time=0.383..0.383 rows=673 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 56kB
  • Buffers: shared hit=2 read=24
15. 0.229 0.229 ↑ 1.0 673 1

Seq Scan on programs (cost=0.00..32.73 rows=673 width=36) (actual time=0.013..0.229 rows=673 loops=1)

  • Buffers: shared hit=2 read=24