explain.depesz.com

PostgreSQL's explain analyze made readable

Result: hc93

Settings
# exclusive inclusive rows x rows loops node
1. 0.015 227.196 ↑ 1.0 1 1

Aggregate (cost=81,549.83..81,549.85 rows=1 width=160) (actual time=227.196..227.196 rows=1 loops=1)

2. 0.016 227.181 ↑ 21.0 20 1

Nested Loop Left Join (cost=1,002.28..81,541.41 rows=420 width=128) (actual time=8.931..227.181 rows=20 loops=1)

3. 0.000 226.985 ↑ 21.0 20 1

Nested Loop Left Join (cost=1,001.85..77,976.66 rows=420 width=100) (actual time=8.895..226.985 rows=20 loops=1)

4. 0.011 226.945 ↑ 21.0 20 1

Nested Loop Left Join (cost=1,001.14..70,834.42 rows=420 width=68) (actual time=8.887..226.945 rows=20 loops=1)

5. 0.000 226.674 ↑ 21.0 20 1

Nested Loop Left Join (cost=1,000.43..63,742.87 rows=420 width=36) (actual time=8.842..226.674 rows=20 loops=1)

6. 62.278 241.188 ↑ 10.5 20 1

Gather (cost=1,000.00..61,919.59 rows=210 width=4) (actual time=8.788..241.188 rows=20 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
7. 178.910 178.910 ↑ 12.6 7 3 / 3

Parallel Seq Scan on roadworkrequest ownrq (cost=0.00..60,898.59 rows=88 width=4) (actual time=68.842..178.910 rows=7 loops=3)

  • Filter: ((psmexportid = 110,250) OR (ownerexportid = 110,250))
  • Rows Removed by Filter: 458,866
8. 0.040 0.220 ↑ 2.0 1 20

GroupAggregate (cost=0.43..8.64 rows=2 width=36) (actual time=0.011..0.011 rows=1 loops=20)

  • Group Key: rrm.roadworkrequestid
9. 0.180 0.180 ↑ 2.0 1 20

Index Scan using ix_roadworkrequestmaterial_roadworkrequestid on roadworkrequestmaterial rrm (cost=0.43..8.61 rows=2 width=10) (actual time=0.009..0.009 rows=1 loops=20)

  • Index Cond: (roadworkrequestid = ownrq.id)
  • Filter: ispsm
  • Rows Removed by Filter: 1
10. 0.000 0.260 ↓ 0.0 0 20

GroupAggregate (cost=0.71..16.86 rows=1 width=36) (actual time=0.013..0.013 rows=0 loops=20)

  • Group Key: rrp.roadworkrequestid
11. 0.000 0.260 ↓ 0.0 0 20

Nested Loop (cost=0.71..16.85 rows=1 width=9) (actual time=0.013..0.013 rows=0 loops=20)

12. 0.260 0.260 ↓ 0.0 0 20

Index Scan using ix_roadworkrequestpenalty_roadworkrequestid on roadworkrequestpenalty rrp (cost=0.42..8.54 rows=1 width=13) (actual time=0.013..0.013 rows=0 loops=20)

  • Index Cond: (roadworkrequestid = ownrq.id)
  • Filter: ispsm
13. 0.000 0.000 ↓ 0.0 0

Index Scan using pk_penalty on penalty p (cost=0.29..8.30 rows=1 width=4) (never executed)

  • Index Cond: (id = rrp.penaltytypeid)
  • Filter: (NOT islegalfee)
14. 0.020 0.040 ↓ 0.0 0 20

GroupAggregate (cost=0.71..16.99 rows=1 width=36) (actual time=0.002..0.002 rows=0 loops=20)

  • Group Key: rrp_1.roadworkrequestid
15. 0.000 0.020 ↓ 0.0 0 20

Nested Loop (cost=0.71..16.97 rows=1 width=9) (actual time=0.001..0.001 rows=0 loops=20)

16. 0.020 0.020 ↓ 0.0 0 20

Index Scan using ix_roadworkrequestpenalty_roadworkrequestid on roadworkrequestpenalty rrp_1 (cost=0.42..8.54 rows=1 width=13) (actual time=0.001..0.001 rows=0 loops=20)

  • Index Cond: (roadworkrequestid = ownrq.id)
  • Filter: ispsm
17. 0.000 0.000 ↓ 0.0 0

Index Scan using pk_penalty on penalty p_1 (cost=0.29..8.30 rows=1 width=4) (never executed)

  • Index Cond: (id = rrp_1.penaltytypeid)
  • Filter: islegalfee
18. 0.040 0.180 ↑ 1.0 1 20

GroupAggregate (cost=0.43..8.47 rows=1 width=36) (actual time=0.009..0.009 rows=1 loops=20)

  • Group Key: rra.roadworkrequestid
19. 0.140 0.140 ↑ 1.0 1 20

Index Scan using idx_roadworkrequestadditional_roadworkrequestid_ispsm on roadworkrequestadditional rra (cost=0.43..8.45 rows=1 width=7) (actual time=0.007..0.007 rows=1 loops=20)

  • Index Cond: ((roadworkrequestid = ownrq.id) AND (ispsm = true))
  • Filter: ispsm