explain.depesz.com

A tool for finding a real cause for slow queries.

Result: Plk

options
Did it help? Consider supporting us - Bitcoin address: 12v2hUztAk2LgzQ9H9LMwuU32urHMjZQnq
# exclusive inclusive rows x rows loops node
1. 31.736 3,330.558 ↑ 1.0 1 1

Aggregate (cost=74,247.68..74,247.69 rows=1 width=0) (actual time=3,330.558..3,330.558 rows=1 loops=1)

  • Buffers: shared hit=16771 read=10736
2. 90.280 3,298.822 ↓ 1.0 275,428 1

Hash Join (cost=53,292.23..73,585.59 rows=264,833 width=0) (actual time=2,184.223..3,298.822 rows=275,428 loops=1)

  • Hash Cond: (cp.contestid = c.id)
  • Buffers: shared hit=16771 read=10736
3. 780.810 3,205.449 ↓ 1.0 275,428 1

Hash Right Join (cost=53,205.86..69,857.77 rows=264,833 width=8) (actual time=2,181.089..3,205.449 rows=275,428 loops=1)

  • Hash Cond: (tm.contestparticipantid = cp.id)
  • Buffers: shared hit=16769 read=10676
4. 244.206 244.206 ↑ 1.0 479,481 1

Seq Scan on teammember tm (cost=0.00..10,428.81 rows=479,481 width=8) (actual time=0.031..244.206 rows=479,481 loops=1)

  • Buffers: shared hit=2 read=5632
5. 110.190 2,180.433 ↓ 1.0 267,278 1

Hash (cost=49,895.45..49,895.45 rows=264,833 width=16) (actual time=2,180.433..2,180.433 rows=267,278 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 12529kB
  • Buffers: shared hit=16767 read=5044
6. 123.887 2,070.243 ↓ 1.0 267,278 1

Hash Right Join (cost=49,201.74..49,895.45 rows=264,833 width=16) (actual time=1,934.848..2,070.243 rows=267,278 loops=1)

  • Hash Cond: (sm.contestparticipantid = cp.id)
  • Buffers: shared hit=16767 read=5044
7. 12.161 12.161 ↑ 1.0 16,742 1

Seq Scan on staffmember sm (cost=0.00..476.42 rows=16,742 width=8) (actual time=0.011..12.161 rows=16,742 loops=1)

  • Buffers: shared hit=2 read=307
8. 131.415 1,934.195 ↓ 1.0 267,258 1

Hash (cost=45,891.32..45,891.32 rows=264,833 width=16) (actual time=1,934.195..1,934.195 rows=267,258 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 12528kB
  • Buffers: shared hit=16765 read=4737
9. 768.713 1,802.780 ↓ 1.0 267,258 1

Hash Join (cost=27,625.03..45,891.32 rows=264,833 width=16) (actual time=812.538..1,802.780 rows=267,258 loops=1)

  • Hash Cond: (cp.personinfoid = pi.id)
  • Buffers: shared hit=16765 read=4737
10. 222.216 222.216 ↑ 1.0 483,376 1

Seq Scan on contestparticipant cp (cost=0.00..9,575.76 rows=483,376 width=32) (actual time=0.013..222.216 rows=483,376 loops=1)

  • Buffers: shared hit=5 read=4737
11. 134.340 811.851 ↓ 1.0 278,282 1

Hash (cost=24,219.33..24,219.33 rows=272,456 width=8) (actual time=811.851..811.851 rows=278,282 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 10871kB
  • Buffers: shared hit=16760
12. 677.511 677.511 ↓ 1.0 278,282 1

Seq Scan on personinfo pi (cost=0.00..24,219.33 rows=272,456 width=8) (actual time=0.037..677.511 rows=278,282 loops=1)

  • Filter: (((lastname)::text ~~ '%b%'::text) OR ((firstname)::text ~~ '%a%'::text))
  • Rows Removed by Filter: 219007
  • Buffers: shared hit=16760
13. 0.504 3.093 ↑ 1.0 1,083 1

Hash (cost=72.83..72.83 rows=1,083 width=8) (actual time=3.093..3.093 rows=1,083 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 43kB
  • Buffers: shared hit=2 read=60
14. 2.589 2.589 ↑ 1.0 1,083 1

Seq Scan on contest c (cost=0.00..72.83 rows=1,083 width=8) (actual time=0.013..2.589 rows=1,083 loops=1)

  • Buffers: shared hit=2 read=60