explain.depesz.com

PostgreSQL's explain analyze made readable

Result: F319 : Optimization for: Optimization for: Optimization for: Optimization for: plan #gCJ3; plan #EMZK; plan #NiDq; plan #xiqO

Settings

Optimization path:

# exclusive inclusive rows x rows loops node
1. 0.069 2,400.330 ↑ 1.0 1 1

Aggregate (cost=1,976,489.36..1,976,489.37 rows=1 width=8) (actual time=2,400.330..2,400.330 rows=1 loops=1)

2. 1.504 2,400.261 ↑ 7.7 1,179 1

Group (cost=1,976,330.92..1,976,376.19 rows=9,054 width=46) (actual time=2,397.414..2,400.261 rows=1,179 loops=1)

  • Group Key: vcarticle.vcarticle_tag
3. 47.593 2,398.757 ↓ 2.7 24,022 1

Sort (cost=1,976,330.92..1,976,353.55 rows=9,054 width=14) (actual time=2,397.413..2,398.757 rows=24,022 loops=1)

  • Sort Key: vcarticle.vcarticle_tag
  • Sort Method: quicksort Memory: 2378kB
4. 6.358 2,351.164 ↓ 2.7 24,022 1

Hash Join (cost=447,468.48..1,975,735.87 rows=9,054 width=14) (actual time=467.859..2,351.164 rows=24,022 loops=1)

  • Hash Cond: (vcentete.vcentete_adhetablissement_id = adhetablissement.adhetablissement_id)
5. 19.651 2,344.709 ↑ 1.0 26,363 1

Nested Loop (cost=447,452.33..1,975,527.40 rows=27,162 width=22) (actual time=467.753..2,344.709 rows=26,363 loops=1)

6. 399.898 2,272.332 ↑ 1.0 26,363 1

Hash Join (cost=447,451.89..1,930,341.71 rows=27,281 width=22) (actual time=467.739..2,272.332 rows=26,363 loops=1)

  • Hash Cond: (vcligne.vcligne_vcarticle_id = vcarticle.vcarticle_id)
7. 1,419.289 1,658.636 ↓ 1.0 1,904,249 1

Bitmap Heap Scan on vcligne (cost=52,007.97..1,508,411.77 rows=1,835,256 width=12) (actual time=253.149..1,658.636 rows=1,904,249 loops=1)

  • Recheck Cond: ((vcligne_dossier_id = 15) AND (vcligne_date >= '2019-01-01 00:00:00'::timestamp without time zone) AND (vcligne_date <= '2019-10-04 23:59:59.999999'::timestamp without time zone))
  • Rows Removed by Index Recheck: 206026
  • Filter: ((vcligne_typelotcalc)::text = ANY ('{"Article simple","Article lot détail","Article assemblé détail"}'::text[]))
  • Rows Removed by Filter: 188
  • Heap Blocks: exact=64598 lossy=133059
8. 239.347 239.347 ↓ 1.0 1,919,038 1

Bitmap Index Scan on vcligne_date_sk (cost=0.00..51,549.16 rows=1,836,848 width=0) (actual time=239.347..239.347 rows=1,919,038 loops=1)

  • Index Cond: ((vcligne_dossier_id = 15) AND (vcligne_date >= '2019-01-01 00:00:00'::timestamp without time zone) AND (vcligne_date <= '2019-10-04 23:59:59.999999'::timestamp without time zone))
9. 49.094 213.798 ↓ 1.1 253,175 1

Hash (cost=391,036.28..391,036.28 rows=240,051 width=22) (actual time=213.798..213.798 rows=253,175 loops=1)

  • Buckets: 262144 Batches: 2 Memory Usage: 9280kB
10. 164.704 164.704 ↓ 1.1 253,175 1

Index Scan using vcarticle_vcclassif2_sk on vcarticle (cost=0.56..391,036.28 rows=240,051 width=22) (actual time=0.024..164.704 rows=253,175 loops=1)

  • Index Cond: ((vcarticle_dossier_id = 15) AND ((vcarticle_vcclassif2)::text = 'COUVERT COULEUR'::text))
11. 52.726 52.726 ↑ 1.0 1 26,363

Index Scan using vcentete_pk on vcentete (cost=0.43..1.65 rows=1 width=12) (actual time=0.002..0.002 rows=1 loops=26,363)

  • Index Cond: (vcentete_id = vcligne.vcligne_vcentete_id)
  • Filter: (vcentete_dossier_id = 15)
12. 0.010 0.097 ↓ 1.0 109 1

Hash (cost=14.81..14.81 rows=107 width=8) (actual time=0.097..0.097 rows=109 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 13kB
13. 0.087 0.087 ↓ 1.0 109 1

Seq Scan on adhetablissement (cost=0.00..14.81 rows=107 width=8) (actual time=0.009..0.087 rows=109 loops=1)

  • Filter: ((adhetablissement_dossier_id = 15) AND ((adhetablissement_enseignelib)::text = 'Ambiance & Styles'::text))
  • Rows Removed by Filter: 219
Planning time : 0.707 ms