explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Fnvu : 9

Settings
# exclusive inclusive rows x rows loops node
1. 0.002 174,269.021 ↓ 0.0 0 1

Unique (cost=50,761.90..50,762.42 rows=5 width=449) (actual time=174,269.021..174,269.021 rows=0 loops=1)

2. 5.354 174,269.019 ↓ 0.0 0 1

Sort (cost=50,761.90..50,761.92 rows=5 width=449) (actual time=174,269.019..174,269.019 rows=0 loops=1)

  • Sort Key: a0.n_cadre, a0.t_cadre, a3.l_action, a4.l_cadre, a5.l_reglem, a6.c_commune, a6.c_point, a0.d_debval,a0.d_finval, a2.d_debut, a2.d_fin, (to_char(a2.h_debut, 'HH24:MI'::text)), (to_char(a2.h_fin, 'HH24:MI'::text)), a0.n_pourcent, a0.l_commobj, a0.l_alerte, a6.mnemo, a3.c_action, a4.c_cadract, a5.c_reglem, a7.n_activite, a8.c_affich, a2.c_axe, a2.c_ident, a2.c_sens, a2.c_dom, a0.c_prog, a0.condreal, a0.c_autorite, a9.l_commune, a0.l_autorite, a0.acs_autorite, a6.n_latitude_degre, a6.n_latitude_minute, a6.n_latitude_seconde, a6.c_latitude_sens, a6.n_longitude_degre, a6.n_longitude_minute, a6.n_longitude_seconde, a6.c_longitude_sens
  • Sort Method: quicksort Memory: 25kB
3. 0.000 174,263.665 ↓ 0.0 0 1

Nested Loop Left Join (cost=2.84..50,761.85 rows=5 width=449) (actual time=174,263.665..174,263.665 rows=0 loops=1)

4. 0.002 174,263.666 ↓ 0.0 0 1

Nested Loop Left Join (cost=2.27..50,742.84 rows=3 width=393) (actual time=174,263.665..174,263.666 rows=0 loops=1)

  • Join Filter: (a2.c_departement = a8.c_departement)
5. 0.002 174,263.664 ↓ 0.0 0 1

Nested Loop Left Join (cost=2.27..50,735.29 rows=3 width=398) (actual time=174,263.663..174,263.664 rows=0 loops=1)

  • Join Filter: ((a2.c_reglem)::text = (a5.c_reglem)::text)
6. 0.001 174,263.662 ↓ 0.0 0 1

Nested Loop Left Join (cost=2.27..50,723.68 rows=3 width=373) (actual time=174,263.662..174,263.662 rows=0 loops=1)

  • Join Filter: ((a2.c_cadract)::text = (a4.c_cadract)::text)
7. 0.002 174,263.661 ↓ 0.0 0 1

Nested Loop Left Join (cost=2.27..50,719.23 rows=3 width=355) (actual time=174,263.661..174,263.661 rows=0 loops=1)

  • Join Filter: ((a2.c_action)::text = (a3.c_action)::text)
8. 5.745 174,263.659 ↓ 0.0 0 1

Nested Loop Left Join (cost=2.27..50,716.45 rows=3 width=333) (actual time=174,263.659..174,263.659 rows=0 loops=1)

  • Filter: (((a2.d_debut IS NULL) AND (a0.d_debval <= '2017-10-09 00:00:00'::timestamp without time zone) AND ((a0.d_finval IS NULL) OR (a0.d_finval > '2017-10-09 00:00:00'::timestamp without time zone))) OR ((a2.d_debut IS NOT NULL) AND (a2.d_debut >= '2017-10-09 00:00:00'::timestamp without time zone) AND (a2.d_debut < '2017-10-10 00:00:00'::timestamp without time zone)))
  • Rows Removed by Filter: 7
9. 59.037 172,825.819 ↑ 8.0 7 1

Merge Join (cost=1.13..50,030.76 rows=56 width=192) (actual time=102,813.873..172,825.819 rows=7 loops=1)

  • Merge Cond: (((a0.t_cadre)::text = (a1.t_cadre)::text) AND (a0.n_cadre = a1.n_cadre))
10. 172,011.161 172,011.161 ↑ 7.0 5,094 1

Index Scan using cadremission_pkey on cadremission a0 (cost=0.56..47,323.62 rows=35,443 width=181) (actual time=273.928..172,011.161 rows=5,094 loops=1)

  • Index Cond: ((t_cadre)::text = ANY ('{AC,OS,OGA,OGG,OGR,OL,AV}'::text[]))
11. 755.621 755.621 ↓ 1.1 72,372 1

Index Only Scan using cadremissionunite_pkey on cadremissionunite a1 (cost=0.56..2,196.08 rows=66,658 width=22) (actual time=605.719..755.621 rows=72,372 loops=1)

  • Index Cond: (c_unite = 'HIE2050439'::text)
  • Heap Fetches: 0
12. 0.056 1,432.095 ↑ 1.0 1 7

Nested Loop Left Join (cost=1.15..12.22 rows=1 width=157) (actual time=204.581..204.585 rows=1 loops=7)

13. 0.119 1,346.156 ↑ 1.0 1 7

Nested Loop Left Join (cost=0.85..9.25 rows=1 width=145) (actual time=192.306..192.308 rows=1 loops=7)

14. 1,294.251 1,294.251 ↑ 1.0 1 7

Index Scan using activite_pkey on activite a2 (cost=0.57..6.31 rows=1 width=87) (actual time=184.891..184.893 rows=1 loops=7)

  • Index Cond: (a0.n_activite = n_activite)
15. 51.786 51.786 ↓ 0.0 0 7

Index Scan using secpoint_pkey on secpoint a6 (cost=0.29..2.93 rows=1 width=74) (actual time=7.398..7.398 rows=0 loops=7)

  • Index Cond: ((a2.c_commune = c_commune) AND (a2.c_point = c_point))
16. 85.883 85.883 ↓ 0.0 0 7

Index Scan using commune_pkey on commune a9 (cost=0.29..2.97 rows=1 width=20) (actual time=12.269..12.269 rows=0 loops=7)

  • Index Cond: (a6.c_commune = c_commune)
17. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..1.47 rows=31 width=25) (never executed)

18. 0.000 0.000 ↓ 0.0 0

Seq Scan on action a3 (cost=0.00..1.31 rows=31 width=25) (never executed)

19. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..1.90 rows=60 width=22) (never executed)

20. 0.000 0.000 ↓ 0.0 0

Seq Scan on cadraction a4 (cost=0.00..1.60 rows=60 width=22) (never executed)

21. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..4.50 rows=167 width=29) (never executed)

22. 0.000 0.000 ↓ 0.0 0

Seq Scan on reglem a5 (cost=0.00..3.67 rows=167 width=29) (never executed)

23. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..2.71 rows=114 width=11) (never executed)

24. 0.000 0.000 ↓ 0.0 0

Seq Scan on departement a8 (cost=0.00..2.14 rows=114 width=11) (never executed)

25. 0.000 0.000 ↓ 0.0 0

Index Scan using user_index_activite3 on activite a7 (cost=0.57..6.32 rows=1 width=19) (never executed)

  • Index Cond: (((a0.t_cadre)::text = (t_cadre_realise)::text) AND (a0.n_cadre = n_cadre_realise))