explain.depesz.com

A tool for finding a real cause for slow queries.

Result: EDC

options
Did it help? Consider supporting us - Bitcoin address: 12v2hUztAk2LgzQ9H9LMwuU32urHMjZQnq
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Sort (cost=17,093.56..17,093.56 rows=1 width=168) (actual time=.. rows= loops=)

  • Sort Key: dossier_hebergement.uid
2. 0.000 0.000 ↓ 0.0

Nested Loop (cost=13.77..17,093.55 rows=1 width=168) (actual time=.. rows= loops=)

3. 0.000 0.000 ↓ 0.0

Nested Loop (cost=13.77..17,001.34 rows=1 width=158) (actual time=.. rows= loops=)

4. 0.000 0.000 ↓ 0.0

Nested Loop (cost=13.77..16,995.40 rows=1 width=131) (actual time=.. rows= loops=)

5. 0.000 0.000 ↓ 0.0

Nested Loop (cost=13.77..16,989.57 rows=1 width=103) (actual time=.. rows= loops=)

6. 0.000 0.000 ↓ 0.0

Nested Loop (cost=13.77..16,983.85 rows=1 width=103) (actual time=.. rows= loops=)

  • Join Filter: ("inner".uid = "outer".ref_type_etat_dossier)
7. 0.000 0.000 ↓ 0.0

Nested Loop (cost=13.77..16,982.71 rows=1 width=75) (actual time=.. rows= loops=)

  • Join Filter: ("inner"."?column2?" = "outer".ref_agent_auth_user)
8. 0.000 0.000 ↓ 0.0

Seq Scan on dossier_hebergement (cost=0.00..16,961.03 rows=1 width=47) (actual time=.. rows= loops=)

  • Filter: ((date_debut >= '2012-04-01'::date) AND (date_debut <= '2012-05-31'::date))
9. 0.000 0.000 ↓ 0.0

Unique (cost=13.77..18.45 rows=144 width=186) (actual time=.. rows= loops=)

10. 0.000 0.000 ↓ 0.0

Sort (cost=13.77..14.13 rows=144 width=186) (actual time=.. rows= loops=)

  • Sort Key: uid, id, username, first_name, last_name, email, "password", is_staff, is_active, is_superuser, last_login
11. 0.000 0.000 ↓ 0.0

Append (cost=0.00..8.61 rows=144 width=186) (actual time=.. rows= loops=)

12. 0.000 0.000 ↓ 0.0

Seq Scan on utilisateur (cost=0.00..7.16 rows=143 width=186) (actual time=.. rows= loops=)

  • Filter: (uid <> 0)
13. 0.000 0.000 ↓ 0.0

Subquery Scan "*SELECT* 2" (cost=0.00..0.02 rows=1 width=0) (actual time=.. rows= loops=)

14. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=0) (actual time=.. rows= loops=)

15. 0.000 0.000 ↓ 0.0

Seq Scan on type_etat_dossier (cost=0.00..1.06 rows=6 width=36) (actual time=.. rows= loops=)

16. 0.000 0.000 ↓ 0.0

Index Scan using idx_payeur_organisme_uid on payeur_organisme (cost=0.00..5.71 rows=1 width=8) (actual time=.. rows= loops=)

  • Index Cond: (payeur_organisme.uid = "outer".ref_payeur_organisme)
17. 0.000 0.000 ↓ 0.0

Index Scan using idx_organisme_uid on organisme (cost=0.00..5.82 rows=1 width=36) (actual time=.. rows= loops=)

  • Index Cond: (organisme.uid = "outer".ref_organisme)
18. 0.000 0.000 ↓ 0.0

Index Scan using famille_cle_key on famille (cost=0.00..5.93 rows=1 width=36) (actual time=.. rows= loops=)

  • Index Cond: (famille.cle = "outer".cle_famille)
  • Filter: (statut >= 0)
19. 0.000 0.000 ↓ 0.0

Index Scan using idx_personne_ref_famille on personne p (cost=0.00..12.65 rows=1 width=14) (actual time=.. rows= loops=)

  • Index Cond: (p.ref_famille = "outer".uid)
  • Filter: ((statut >= 0) AND chef_de_famille AND (nom ~~* '%%'::text) AND (prenom ~~* '%%'::text))
20.          

SubPlan (forNested Loop)

21. 0.000 0.000 ↓ 0.0

Limit (cost=4.46..21.52 rows=1 width=57) (actual time=.. rows= loops=)

22. 0.000 0.000 ↓ 0.0

Nested Loop (cost=4.46..21.52 rows=1 width=57) (actual time=.. rows= loops=)

  • Join Filter: ("inner".uid = "outer".ref_prestataire)
23. 0.000 0.000 ↓ 0.0

Nested Loop (cost=4.46..20.31 rows=1 width=29) (actual time=.. rows= loops=)

24. 0.000 0.000 ↓ 0.0

Nested Loop (cost=4.46..14.49 rows=1 width=8) (actual time=.. rows= loops=)

25. 0.000 0.000 ↓ 0.0

Bitmap Heap Scan on reservation (cost=4.46..8.48 rows=1 width=4) (actual time=.. rows= loops=)

  • Recheck Cond: ((ref_dossier_hebergement = $1) AND (ref_famille = $0))
  • Filter: ((statut = 0) AND (ref_dossier_hebergement <> 0))
26. 0.000 0.000 ↓ 0.0

BitmapAnd (cost=4.46..4.46 rows=1 width=0) (actual time=.. rows= loops=)

27. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on idx_ion_ref_dossier_hebergement (cost=0.00..2.01 rows=3 width=0) (actual time=.. rows= loops=)

  • Index Cond: (ref_dossier_hebergement = $1)
28. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on idx_reservation_ref_famille (cost=0.00..2.20 rows=57 width=0) (actual time=.. rows= loops=)

  • Index Cond: (ref_famille = $0)
29. 0.000 0.000 ↓ 0.0

Index Scan using idx_chambre_uid on chambre (cost=0.00..5.99 rows=1 width=12) (actual time=.. rows= loops=)

  • Index Cond: ("outer".ref_chambre = chambre.uid)
30. 0.000 0.000 ↓ 0.0

Index Scan using idx_hotel_uid on hotel (cost=0.00..5.82 rows=1 width=29) (actual time=.. rows= loops=)

  • Index Cond: ("outer".ref_hotel = hotel.uid)
31. 0.000 0.000 ↓ 0.0

Seq Scan on prestataire (cost=0.00..1.09 rows=9 width=36) (actual time=.. rows= loops=)

32. 0.000 0.000 ↓ 0.0

Limit (cost=0.00..58.02 rows=1 width=57) (actual time=.. rows= loops=)

33. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.00..290.11 rows=5 width=57) (actual time=.. rows= loops=)

  • Join Filter: ("inner".uid = "outer".ref_prestataire)
34. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.00..284.10 rows=5 width=29) (actual time=.. rows= loops=)

35. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.00..254.95 rows=5 width=8) (actual time=.. rows= loops=)

36. 0.000 0.000 ↓ 0.0

Index Scan using idx_reservation_ref_famille on reservation (cost=0.00..224.93 rows=5 width=4) (actual time=.. rows= loops=)

  • Index Cond: (ref_famille = $0)
  • Filter: ((statut = 0) AND (ref_dossier_hebergement <> $1) AND ($2 >= date_debut) AND ($2 <= date_fin))
37. 0.000 0.000 ↓ 0.0

Index Scan using idx_chambre_uid on chambre (cost=0.00..5.99 rows=1 width=12) (actual time=.. rows= loops=)

  • Index Cond: ("outer".ref_chambre = chambre.uid)
38. 0.000 0.000 ↓ 0.0

Index Scan using idx_hotel_uid on hotel (cost=0.00..5.82 rows=1 width=29) (actual time=.. rows= loops=)

  • Index Cond: ("outer".ref_hotel = hotel.uid)
39. 0.000 0.000 ↓ 0.0

Seq Scan on prestataire (cost=0.00..1.09 rows=9 width=36) (actual time=.. rows= loops=)