explain.depesz.com

PostgreSQL's explain analyze made readable

Result: obLC

Settings
# exclusive inclusive rows x rows loops node
1. 5.182 2,171.297 ↓ 15.5 1,160 1

GroupAggregate (cost=71,973.04..71,980.88 rows=75 width=104) (actual time=2,164.757..2,171.297 rows=1,160 loops=1)

  • Group Key: individu_rapproche.id
2. 4.899 2,166.059 ↓ 92.9 6,971 1

Sort (cost=71,973.04..71,973.23 rows=75 width=18) (actual time=2,164.654..2,166.059 rows=6,971 loops=1)

  • Sort Key: individu_rapproche.id
  • Sort Method: quicksort Memory: 736kB
3. 3.933 2,161.160 ↓ 92.9 6,971 1

Nested Loop (cost=3.85..71,970.70 rows=75 width=18) (actual time=1,088.717..2,161.160 rows=6,971 loops=1)

4. 5.342 2,101.459 ↓ 92.9 6,971 1

Nested Loop (cost=3.29..71,718.99 rows=75 width=14) (actual time=1,081.755..2,101.459 rows=6,971 loops=1)

5. 6.603 1,938.452 ↓ 96.5 6,855 1

Nested Loop (cost=2.72..71,284.16 rows=71 width=26) (actual time=1,081.714..1,938.452 rows=6,855 loops=1)

6. 8.333 1,883.864 ↓ 96.5 6,855 1

Nested Loop (cost=2.15..71,045.65 rows=71 width=18) (actual time=1,081.679..1,883.864 rows=6,855 loops=1)

7. 11.208 1,371.435 ↓ 80.9 42,008 1

Nested Loop (cost=1.57..7,328.15 rows=519 width=16) (actual time=46.997..1,371.435 rows=42,008 loops=1)

8. 0.060 48.087 ↑ 1.0 38 1

Nested Loop (cost=1.00..384.17 rows=38 width=8) (actual time=24.563..48.087 rows=38 loops=1)

9. 24.603 24.603 ↓ 1.5 6 1

Index Scan using idx_etablissement_dsn_on_siret on etablissement_dsn e (cost=0.43..15.00 rows=4 width=8) (actual time=16.861..24.603 rows=6 loops=1)

  • Index Cond: ((siret)::text = '85520050700306'::text)
10. 23.424 23.424 ↑ 4.8 6 6

Index Scan using idx_declaration_dsn_on_fk_etablissement_dsn on declaration_dsn d (cost=0.56..92.00 rows=29 width=16) (actual time=3.747..3.904 rows=6 loops=6)

  • Index Cond: (fk_etablissement_dsn = e.id)
  • Filter: dsn_active
  • Rows Removed by Filter: 0
11. 1,312.140 1,312.140 ↑ 2.4 1,105 38

Index Scan using idx_versement_individu_salarie_dsn_on_fk_declaration_dsn on versement_individu_salarie_dsn vers (cost=0.57..155.85 rows=2,689 width=24) (actual time=26.368..34.530 rows=1,105 loops=38)

  • Index Cond: (fk_declaration_dsn = d.id)
12. 504.096 504.096 ↓ 0.0 0 42,008

Index Scan using idx_base_assujettie_on_fk_versement_individu_salarie_dsn on base_assujettie base (cost=0.58..122.30 rows=47 width=18) (actual time=0.011..0.012 rows=0 loops=42,008)

  • Index Cond: (fk_versement_individu_salarie_dsn = vers.id)
  • Filter: ((dt_deb_prd_rattachement >= '2019-01-01'::date) AND (dt_deb_prd_rattachement <= '2019-01-30'::date))
  • Rows Removed by Filter: 7
13. 47.985 47.985 ↑ 1.0 1 6,855

Index Only Scan using pk_individu_salarie_dsn on individu_salarie_dsn indiv (cost=0.57..3.35 rows=1 width=8) (actual time=0.007..0.007 rows=1 loops=6,855)

  • Index Cond: (id = vers.fk_individu_salarie_dsn)
  • Heap Fetches: 0
14. 157.665 157.665 ↑ 1.0 1 6,855

Index Scan using idx_r_individu_salarie_individu_rapproche_fk_individu_salarie on r_individu_salarie_individu_rapproche risi (cost=0.57..6.11 rows=1 width=8) (actual time=0.019..0.023 rows=1 loops=6,855)

  • Index Cond: (fk_individu_salarie_dsn = vers.fk_individu_salarie_dsn)
15. 55.768 55.768 ↑ 1.0 1 6,971

Index Only Scan using pk_individu_rapproche on individu_rapproche (cost=0.56..3.35 rows=1 width=8) (actual time=0.008..0.008 rows=1 loops=6,971)

  • Index Cond: (id = risi.fk_individu_rapproche)
  • Heap Fetches: 0
16.          

SubPlan (for GroupAggregate)

17. 0.034 0.034 ↑ 1.0 1 1

Seq Scan on type_base_assujettie type_base_assujettie_2 (cost=0.00..1.68 rows=1 width=4) (actual time=0.024..0.034 rows=1 loops=1)

  • Filter: (code = '04'::bpchar)
  • Rows Removed by Filter: 53
18. 0.011 0.011 ↑ 1.0 1 1

Seq Scan on type_base_assujettie type_base_assujettie_1 (cost=0.00..1.68 rows=1 width=4) (actual time=0.004..0.011 rows=1 loops=1)

  • Filter: (code = '02'::bpchar)
  • Rows Removed by Filter: 53
19. 0.011 0.011 ↑ 1.0 1 1

Seq Scan on type_base_assujettie (cost=0.00..1.68 rows=1 width=4) (actual time=0.004..0.011 rows=1 loops=1)

  • Filter: (code = '03'::bpchar)
  • Rows Removed by Filter: 53
Planning time : 4.948 ms
Execution time : 2,171.561 ms