explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 9a2Y

Settings
# exclusive inclusive rows x rows loops node
1. 4.114 92.306 ↑ 13.5 319 1

HashAggregate (cost=18,025.82..18,111.92 rows=4,305 width=48) (actual time=92.268..92.306 rows=319 loops=1)

  • Group Key: (((s.annee)::text || ' - '::text) || a.libelle)
2.          

Initplan (forHashAggregate)

3. 0.003 0.003 ↑ 1.0 1 1

Result (cost=0.00..0.02 rows=1 width=8) (actual time=0.003..0.003 rows=1 loops=1)

4. 4.937 88.189 ↓ 3.9 16,925 1

Hash Left Join (cost=180.71..17,971.98 rows=4,305 width=40) (actual time=67.138..88.189 rows=16,925 loops=1)

  • Hash Cond: (v.appellation_id = a.id)
5. 2.358 83.183 ↓ 3.9 16,925 1

Hash Join (cost=170.53..17,859.56 rows=4,305 width=16) (actual time=67.060..83.183 rows=16,925 loops=1)

  • Hash Cond: (s.contenant_id = c.id)
6. 3.012 80.816 ↓ 3.9 16,925 1

Hash Join (cost=169.46..17,799.30 rows=4,305 width=16) (actual time=67.044..80.816 rows=16,925 loops=1)

  • Hash Cond: (s.vin_id = v.id)
7. 76.689 76.689 ↓ 3.9 16,925 1

Seq Scan on stock s (cost=0.00..17,570.64 rows=4,305 width=16) (actual time=65.899..76.689 rows=16,925 loops=1)

  • Filter: ($0 = (annee)::double precision)
  • Rows Removed by Filter: 844118
8. 0.583 1.115 ↑ 1.0 6,065 1

Hash (cost=93.65..93.65 rows=6,065 width=8) (actual time=1.115..1.115 rows=6,065 loops=1)

  • Buckets: 8192 Batches: 1 Memory Usage: 301kB
9. 0.532 0.532 ↑ 1.0 6,065 1

Seq Scan on vin v (cost=0.00..93.65 rows=6,065 width=8) (actual time=0.006..0.532 rows=6,065 loops=1)

10. 0.003 0.009 ↑ 1.0 3 1

Hash (cost=1.03..1.03 rows=3 width=8) (actual time=0.009..0.009 rows=3 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
11. 0.006 0.006 ↑ 1.0 3 1

Seq Scan on contenant c (cost=0.00..1.03 rows=3 width=8) (actual time=0.004..0.006 rows=3 loops=1)

12. 0.039 0.069 ↑ 1.0 319 1

Hash (cost=6.19..6.19 rows=319 width=20) (actual time=0.069..0.069 rows=319 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 25kB
13. 0.030 0.030 ↑ 1.0 319 1

Seq Scan on appellation a (cost=0.00..6.19 rows=319 width=20) (actual time=0.004..0.030 rows=319 loops=1)