explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Epcg

Settings
# exclusive inclusive rows x rows loops node
1. 1,346.902 95,221.031 ↑ 88,195.5 2 1

GroupAggregate (cost=411,519.48..415,488.27 rows=176,391 width=33) (actual time=93,887.374..95,221.031 rows=2 loops=1)

  • Group Key: o.outcome_type_cname, o.name, o.cname
2. 3,271.354 93,874.129 ↑ 1.1 167,592 1

Sort (cost=411,519.48..411,960.45 rows=176,391 width=33) (actual time=92,525.498..93,874.129 rows=167,592 loops=1)

  • Sort Key: o.outcome_type_cname, o.name, o.cname
  • Sort Method: external merge Disk: 5232kB
3. 4,562.356 90,602.775 ↑ 1.1 167,592 1

Nested Loop (cost=3,011.97..391,321.90 rows=176,391 width=33) (actual time=1,170.150..90,602.775 rows=167,592 loops=1)

4. 1,929.627 75,959.033 ↓ 2.0 113,274 1

Hash Join (cost=3,011.53..231,214.61 rows=55,770 width=4) (actual time=1,169.450..75,959.033 rows=113,274 loops=1)

  • Hash Cond: (m.event_id = e.id)
5. 36,899.683 72,861.303 ↓ 2.0 113,274 1

Hash Join (cost=31.00..226,909.54 rows=55,770 width=8) (actual time=1.303..72,861.303 rows=113,274 loops=1)

  • Hash Cond: ((m.name)::text = (mt.name)::text)
6. 35,961.269 35,961.269 ↑ 1.0 4,388,315 1

Seq Scan on markets m (cost=0.00..138,528.28 rows=4,389,628 width=40) (actual time=0.022..35,961.269 rows=4,388,315 loops=1)

7. 0.118 0.351 ↑ 1.0 14 1

Hash (cost=30.83..30.83 rows=14 width=33) (actual time=0.351..0.351 rows=14 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 1kB
8. 0.233 0.233 ↑ 1.0 14 1

Seq Scan on market_types mt (cost=0.00..30.83 rows=14 width=33) (actual time=0.076..0.233 rows=14 loops=1)

  • Filter: ((name2)::text = '[Total Goals] X.5'::text)
  • Rows Removed by Filter: 772
9. 595.523 1,168.103 ↑ 1.0 70,468 1

Hash (cost=2,099.68..2,099.68 rows=70,468 width=4) (actual time=1,168.103..1,168.103 rows=70,468 loops=1)

  • Buckets: 8192 Batches: 1 Memory Usage: 2478kB
10. 572.580 572.580 ↑ 1.0 70,468 1

Seq Scan on events e (cost=0.00..2,099.68 rows=70,468 width=4) (actual time=0.013..572.580 rows=70,468 loops=1)

11. 10,081.386 10,081.386 ↑ 74.0 1 113,274

Index Scan using outcomes_market_id_index on outcomes o (cost=0.43..2.13 rows=74 width=37) (actual time=0.076..0.089 rows=1 loops=113,274)

  • Index Cond: (market_id = m.id)
Planning time : 7.332 ms
Execution time : 95,222.586 ms