explain.depesz.com

PostgreSQL's explain analyze made readable

Result: kxue

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Limit (cost=810,836.13..810,836.89 rows=9 width=334) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Unique (cost=810,836.13..810,836.89 rows=9 width=334) (actual rows= loops=)

3. 0.000 0.000 ↓ 0.0

Sort (cost=810,836.13..810,836.15 rows=9 width=334) (actual rows= loops=)

  • Sort Key: ordrefabri1_.datefinreelle DESC, ordrefabri1_.codeof, operationo0_.numeroordreoperationof, articleent2_.code, articleent2_.designation, ((SubPlan 1)), ((SubPlan 2)), ((SubPlan 3)), articleent2_.prixvente_valeur, ordrefabri1_.referen (...)
4. 0.000 0.000 ↓ 0.0

HashAggregate (cost=810,000.11..810,835.98 rows=9 width=334) (actual rows= loops=)

  • Group Key: ordrefabri1_.datefinreelle, ordrefabri1_.codeof, operationo0_.numeroordreoperationof, articleent2_.code, articleent2_.designation, (SubPlan 1), (SubPlan 2), (SubPlan 3), articleent2_.prixvente_valeur, ordrefabri1_.referenceof (...)
5. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=2.65..809,999.37 rows=9 width=334) (actual rows= loops=)

  • Filter: (listeligne8_3_.datefinvalidite IS NULL)
6. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=2.10..809,117.74 rows=10 width=355) (actual rows= loops=)

  • Join Filter: ((operationo0_.id)::text = (listeligne8_.id_operationordrefabrication)::text)
7. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=2.10..802,038.82 rows=10 width=322) (actual rows= loops=)

  • Filter: (articleent7_.datefinvalidite IS NULL)
8. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.68..802,032.94 rows=10 width=321) (actual rows= loops=)

  • Filter: (listecompo6_.datefinvalidite IS NULL)
9. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.26..802,027.78 rows=10 width=278) (actual rows= loops=)

  • Join Filter: ((operationo0_1_.id_tarifsoustraitance)::text = (tarifsoust5_.id)::text)
  • Filter: (tarifsoust5_.datefinvalidite IS NULL)
10. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.26..801,514.09 rows=10 width=293) (actual rows= loops=)

  • Join Filter: ((operationo0_1_.id_centrecharge)::text = (centrechar4_.id)::text)
  • Filter: (centrechar4_.datefinvalidite IS NULL)
11. 0.000 0.000 ↓ 0.0

Nested Loop (cost=1.26..801,460.54 rows=10 width=277) (actual rows= loops=)

12. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.84..801,453.95 rows=10 width=221) (actual rows= loops=)

13. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.41..801,437.11 rows=2 width=170) (actual rows= loops=)

  • Join Filter: ((articleent2_.id_famillearticle)::text = (familleart3_.id)::text)
  • Filter: (familleart3_.datefinvalidite IS NULL)
14. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.41..801,430.44 rows=2 width=184) (actual rows= loops=)

  • Filter: ((articleent2_.datefinvalidite IS NULL) AND ((coalescelower(articleent2_.designation))::text !~~ '%retouche%'::text) AND (NOT (SubPlan 6)) AND (NOT (SubPlan 7)) AND (NO (...)
15. 0.000 0.000 ↓ 0.0

Seq Scan on dm5_ordrefabrication ordrefabri1_ (cost=0.00..786,160.43 rows=243 width=117) (actual rows= loops=)

  • Filter: ((datefinvalidite IS NULL) AND ((datefinreelle)::date >= '2013-01-01'::date) AND ((datefinreelle)::date <= '2019-03-15'::date) AND (NOT (SubPlan 8)))
16.          

SubPlan (forSeq Scan)

17. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=33) (actual rows= loops=)

18. 0.000 0.000 ↓ 0.0

Index Only Scan using dm5_ordrefabrication_pkey on dm5_ordrefabrication ordrefabri24_ (cost=0.42..7.44 rows=1 width=33) (actual rows= loops=)

  • Index Cond: (id = (ordrefabri1_.id)::text)
19. 0.000 0.000 ↓ 0.0

Index Scan using dm5_ordrefabrication_cs_pkey on dm5_ordrefabrication_cs attributsu25_ (cost=0.55..7.58 rows=1 width=33) (actual rows= loops=)

  • Index Cond: (((id_ordrefabrication)::text = (ordrefabri1_.id)::text) AND ((clef)::text = 'sup_OrdreFabrication_impression_logistique'::text))
  • Filter: ((alpha)::text = '1'::text)
20. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_pkey on dm1_article articleent2_ (cost=0.41..6.57 rows=1 width=108) (actual rows= loops=)

  • Index Cond: ((ordrefabri1_.id_article)::text = (id)::text)
21.          

SubPlan (forNested Loop Left Join)

22. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=32) (actual rows= loops=)

23. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent20_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
24. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu21_ (cost=0.56..7.58 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_type_article'::text))
  • Filter: ((alpha)::text = '0'::text)
25. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=32) (actual rows= loops=)

26. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent22_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
27. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu23_ (cost=0.56..7.58 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_type_article'::text))
  • Filter: ((alpha)::text = '3'::text)
28. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=32) (actual rows= loops=)

29. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent26_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
30. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu27_ (cost=0.56..7.58 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_type_article'::text))
  • Filter: ((alpha)::text = '4'::text)
31. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=32) (actual rows= loops=)

32. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent28_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
33. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu29_ (cost=0.56..7.58 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_type_article'::text))
  • Filter: ((alpha)::text = '5'::text)
34. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=32) (actual rows= loops=)

35. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent30_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
36. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu31_ (cost=0.56..7.58 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_type_article'::text))
  • Filter: ((alpha)::text = '6'::text)
37. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=32) (actual rows= loops=)

38. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent32_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
39. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu33_ (cost=0.56..7.58 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_type_article'::text))
  • Filter: ((alpha)::text = '7'::text)
40. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=32) (actual rows= loops=)

41. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent34_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
42. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu35_ (cost=0.56..7.58 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_type_article'::text))
  • Filter: ((alpha)::text = '9'::text)
43. 0.000 0.000 ↓ 0.0

Materialize (cost=0.00..3.65 rows=110 width=59) (actual rows= loops=)

44. 0.000 0.000 ↓ 0.0

Seq Scan on dm1_famillearticle familleart3_ (cost=0.00..3.10 rows=110 width=59) (actual rows= loops=)

45. 0.000 0.000 ↓ 0.0

Index Scan using x_dm5_operationordrefabrication_04 on dm5_operationordrefabrication operationo0_ (cost=0.42..8.35 rows=7 width=117) (actual rows= loops=)

  • Index Cond: ((id_ordrefabrication)::text = (ordrefabri1_.id)::text)
  • Filter: ((id)::text !~~ 'DefaultRecord_%'::text)
46. 0.000 0.000 ↓ 0.0

Index Scan using dm1_operation_pkey on dm1_operation operationo0_1_ (cost=0.42..0.65 rows=1 width=89) (actual rows= loops=)

  • Index Cond: ((id)::text = (operationo0_.id)::text)
  • Filter: (datefinvalidite IS NULL)
47. 0.000 0.000 ↓ 0.0

Materialize (cost=0.00..14.02 rows=268 width=33) (actual rows= loops=)

48. 0.000 0.000 ↓ 0.0

Seq Scan on dm3_centrecharge centrechar4_ (cost=0.00..12.68 rows=268 width=33) (actual rows= loops=)

49. 0.000 0.000 ↓ 0.0

Materialize (cost=0.00..119.13 rows=2,675 width=59) (actual rows= loops=)

50. 0.000 0.000 ↓ 0.0

Seq Scan on dm4_tarifsoustraitance tarifsoust5_ (cost=0.00..105.75 rows=2,675 width=59) (actual rows= loops=)

51. 0.000 0.000 ↓ 0.0

Index Scan using x_dm5_composantordrefabrication_06 on dm5_composantordrefabrication listecompo6_ (cost=0.42..0.50 rows=2 width=84) (actual rows= loops=)

  • Index Cond: ((operationo0_.id)::text = (id_operationordrefabrication)::text)
52. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_pkey on dm1_article articleent7_ (cost=0.41..0.58 rows=1 width=74) (actual rows= loops=)

  • Index Cond: ((listecompo6_.id_article)::text = (id)::text)
53. 0.000 0.000 ↓ 0.0

Materialize (cost=0.00..1,105.47 rows=40,498 width=66) (actual rows= loops=)

54. 0.000 0.000 ↓ 0.0

Seq Scan on dm4_lignecommandeachatsoustraitance listeligne8_ (cost=0.00..902.98 rows=40,498 width=66) (actual rows= loops=)

55. 0.000 0.000 ↓ 0.0

Index Scan using dm1_lignedocumentcommercial_pkey on dm1_lignedocumentcommercial listeligne8_3_ (cost=0.55..4.58 rows=1 width=53) (actual rows= loops=)

  • Index Cond: ((listeligne8_.id)::text = (id)::text)
56.          

SubPlan (forNested Loop Left Join)

57. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=5) (actual rows= loops=)

58. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent9_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
59. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu10_ (cost=0.56..7.58 rows=1 width=37) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_type_article'::text))
60. 0.000 0.000 ↓ 0.0

Nested Loop (cost=1.25..22.32 rows=1 width=6) (actual rows= loops=)

61. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=5) (actual rows= loops=)

62. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent11_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
63. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu12_ (cost=0.56..7.58 rows=1 width=37) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_rcc_saisie_assitee'::text))
64. 0.000 0.000 ↓ 0.0

Index Scan using specif_rccsup_pkey on specif_rccsup rccsupenti13_ (cost=0.28..7.29 rows=1 width=38) (actual rows= loops=)

  • Index Cond: ((id)::text = (attributsu12_.alpha)::text)
65. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.97..15.02 rows=1 width=5) (actual rows= loops=)

66. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_article_pkey on dm1_article articleent14_ (cost=0.41..7.43 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (id = (articleent2_.id)::text)
67. 0.000 0.000 ↓ 0.0

Index Scan using dm1_article_cs_pkey on dm1_article_cs attributsu15_ (cost=0.56..7.58 rows=1 width=37) (actual rows= loops=)

  • Index Cond: (((id_article)::text = (articleent2_.id)::text) AND ((clef)::text = 'sup_Article_acc'::text))
68. 0.000 0.000 ↓ 0.0

Nested Loop (cost=1.41..26.01 rows=3 width=2) (actual rows= loops=)

69. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.85..14.90 rows=1 width=33) (actual rows= loops=)

70. 0.000 0.000 ↓ 0.0

Index Only Scan using dm5_operationordrefabrication_pkey on dm5_operationordrefabrication operationo16_ (cost=0.42..7.44 rows=1 width=33) (actual rows= loops=)

  • Index Cond: (id = (operationo0_.id)::text)
71. 0.000 0.000 ↓ 0.0

Index Only Scan using dm1_operation_pkey on dm1_operation operationo16_1_ (cost=0.42..7.44 rows=1 width=33) (actual rows= loops=)

  • Index Cond: (id = (operationo0_.id)::text)
72. 0.000 0.000 ↓ 0.0

Index Scan using dm1_operation_cs_pkey on dm1_operation_cs attributsu17_ (cost=0.56..11.09 rows=3 width=35) (actual rows= loops=)

  • Index Cond: (((id_operation)::text = (operationo0_.id)::text) AND ((clef)::text = 'sup_OperationOrdreFabrication_valide'::text))
73. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.43..14.48 rows=1 width=1) (actual rows= loops=)

74. 0.000 0.000 ↓ 0.0

Index Only Scan using dm3_poste_pkey on dm3_centrecharge centrechar18_ (cost=0.15..7.17 rows=1 width=6) (actual rows= loops=)

  • Index Cond: (id = (centrechar4_.id)::text)
75. 0.000 0.000 ↓ 0.0

Index Scan using dm3_centrecharge_cs_pkey on dm3_centrecharge_cs attributsu19_ (cost=0.28..7.30 rows=1 width=7) (actual rows= loops=)

  • Index Cond: (((id_centrecharge)::text = (centrechar4_.id)::text) AND ((clef)::text = 'sup_CentreCharge_etude_de_temps'::text))