explain.depesz.com

PostgreSQL's explain analyze made readable

Result: xm9T

Settings
# exclusive inclusive rows x rows loops node
1. 5.545 148,524.610 ↑ 1.0 1 1

Aggregate (cost=16,771,361.73..16,771,361.74 rows=1 width=8) (actual time=148,524.609..148,524.610 rows=1 loops=1)

  • Buffers: shared hit=100702111 read=14226
2. 322.445 148,519.065 ↓ 19.5 25,296 1

Index Scan using idx_fe_mvt_compte_courant_objf_id_cptc_id_dte_valeur on fe_mvt_compte_courant (cost=0.43..16,771,358.49 rows=1,297 width=0) (actual time=7.340..148,519.065 rows=25,296 loops=1)

  • Index Cond: (dte_valeur <= '2009-01-01'::date)
  • Filter: (mvtcc_id = (SubPlan 3))
  • Rows Removed by Filter: 233789
  • Buffers: shared hit=100702111 read=14226
3.          

SubPlan (forIndex Scan)

4. 21,876.110 148,196.620 ↑ 1.0 1 259,085

Aggregate (cost=64.22..64.23 rows=1 width=4) (actual time=0.572..0.572 rows=1 loops=259,085)

  • Buffers: shared hit=100472580 read=12585
  • -> Index Scan using idx_fe_mvt_compte_courant_objf_id_cptc_id_dte_valeur on fe_mvt_compte_courant a (cost=0.43..64.22 rows=1 width=4) (actual time=0.226..0.571 rows=1 loops=25908
  • Index Cond: ((objf_id = fe_mvt_compte_courant.objf_id) AND (cptc_id = fe_mvt_compte_courant.cptc_id))
  • Filter: (dte_valeur = (SubPlan 2))
  • Rows Removed by Filter: 96
  • Buffers: shared hit=100472580 read=12585
5.          

SubPlan (forAggregate)

6. 25,264.102 126,320.510 ↑ 1.0 1 25,264,102

Result (cost=2.45..2.46 rows=1 width=4) (actual time=0.005..0.005 rows=1 loops=25,264,102)

  • Buffers: shared hit=75791977 read=330
7.          

Initplan (forResult)

8. 101,056.408 101,056.408 ↑ 1.0 1 25,264,102

Limit (cost=0.43..2.45 rows=1 width=4) (actual time=0.004..0.004 rows=1 loops=25,264,102)

  • Buffers: shared hit=75791977 read=330
  • -> Index Only Scan Backward using idx_fe_mvt_compte_courant_objf_id_cptc_id_dte_valeur on fe_mvt_compte_courant b (cost=0.43..4.48 rows=2 width=4) (actual t
  • Index Cond: ((objf_id = a.objf_id) AND (cptc_id = a.cptc_id) AND (dte_valeur IS NOT NULL) AND (dte_valeur <= '2009-01-01'::date))
  • Heap Fetches: 0
  • Buffers: shared hit=75791977 read=330