explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 4w3b : SLOW

Settings
# exclusive inclusive rows x rows loops node
1. 12,792.573 50,435.288 ↓ 3,423.0 3,423 1

Nested Loop Left Join (cost=26,116.03..34,072.34 rows=1 width=13) (actual time=263.685..50,435.288 rows=3,423 loops=1)

  • Join Filter: (kk.objekti_id = o.objekti_id)
  • Rows Removed by Join Filter: 258943104
2. 20.522 20.522 ↓ 3,423.0 3,423 1

Seq Scan on objekti o (cost=0.00..7,949.81 rows=1 width=13) (actual time=0.253..20.522 rows=3,423 loops=1)

  • Filter: (projekti_id = 14)
  • Rows Removed by Filter: 72227
3. 37,396.995 37,622.193 ↓ 378.2 75,649 3,423

HashAggregate (cost=26,116.03..26,118.03 rows=200 width=12) (actual time=0.076..10.991 rows=75,649 loops=3,423)

  • Group Key: kk.objekti_id
4. 37.266 225.198 ↓ 1.0 104,876 1

GroupAggregate (cost=16,702.55..24,544.16 rows=104,791 width=20) (actual time=90.948..225.198 rows=104,876 loops=1)

  • Group Key: kk.katovi_id
5. 38.470 187.932 ↓ 1.0 131,722 1

Merge Left Join (cost=16,702.55..22,837.65 rows=131,721 width=20) (actual time=90.932..187.932 rows=131,722 loops=1)

  • Merge Cond: (kk.katovi_id = ddd.katovi_id)
6. 28.657 28.657 ↓ 1.0 104,876 1

Index Scan using katovi_pkey on katovi kk (cost=0.29..3,592.75 rows=104,791 width=12) (actual time=0.006..28.657 rows=104,876 loops=1)

7. 10.836 120.805 ↑ 1.0 131,721 1

Materialize (cost=16,702.19..17,360.79 rows=131,721 width=16) (actual time=90.921..120.805 rows=131,721 loops=1)

8. 89.213 109.969 ↑ 1.0 131,721 1

Sort (cost=16,702.19..17,031.49 rows=131,721 width=16) (actual time=90.914..109.969 rows=131,721 loops=1)

  • Sort Key: ddd.katovi_id
  • Sort Method: external merge Disk: 3344kB
9. 20.756 20.756 ↑ 1.0 131,721 1

Seq Scan on dijelovi ddd (cost=0.00..3,247.21 rows=131,721 width=16) (actual time=0.009..20.756 rows=131,721 loops=1)

Planning time : 0.301 ms
Execution time : 50,438.807 ms