explain.depesz.com

PostgreSQL's explain analyze made readable

Result: TK5n

Settings
# exclusive inclusive rows x rows loops node
1. 4,505.591 14,160.479 ↓ 1.3 105,239 1

Hash Left Join (cost=236,127.36..1,860,984.28 rows=83,818 width=3,254) (actual time=3,271.063..14,160.479 rows=105,239 loops=1)

  • Hash Cond: (tca.id_callback_action = ca.id_callback_action)
2. 2,066.456 9,654.717 ↓ 1.3 105,239 1

Nested Loop Left Join (cost=236,119.36..1,845,784.26 rows=83,818 width=3,200) (actual time=3,270.365..9,654.717 rows=105,239 loops=1)

3. 80.439 7,167.305 ↓ 1.3 105,239 1

Hash Left Join (cost=236,107.82..591,619.37 rows=83,818 width=3,120) (actual time=3,270.328..7,167.305 rows=105,239 loops=1)

  • Hash Cond: (t.id_last_follow_up = fu.id_follow_up)
4. 80.971 7,086.840 ↓ 1.3 105,239 1

Hash Left Join (cost=236,106.58..590,650.69 rows=83,818 width=1,572) (actual time=3,270.289..7,086.840 rows=105,239 loops=1)

  • Hash Cond: (v.id_produit = p.id_produit)
5. 80.125 7,005.841 ↓ 1.3 105,239 1

Hash Left Join (cost=236,105.15..589,718.61 rows=83,818 width=1,060) (actual time=3,270.229..7,005.841 rows=105,239 loops=1)

  • Hash Cond: (t.id_ticket = cat.id_ticket)
6. 58.869 6,922.523 ↓ 1.3 105,239 1

Hash Left Join (cost=211,884.74..560,573.71 rows=83,818 width=1,052) (actual time=3,267.023..6,922.523 rows=105,239 loops=1)

  • Hash Cond: (t.id_ticketing_detail = td.id_ticketing_detail)
7. 130.281 6,863.612 ↓ 1.3 105,239 1

Hash Left Join (cost=211,882.97..560,180.29 rows=83,818 width=638) (actual time=3,266.953..6,863.612 rows=105,239 loops=1)

  • Hash Cond: (thi.id_utilisateur = thu.id_utilisateur)
8. 139.947 6,730.975 ↓ 1.3 105,239 1

Nested Loop Left Join (cost=211,699.06..558,424.78 rows=83,818 width=633) (actual time=3,264.568..6,730.975 rows=105,239 loops=1)

9. 106.732 4,907.204 ↓ 1.3 105,239 1

Hash Join (cost=211,698.62..251,774.78 rows=83,818 width=625) (actual time=3,264.476..4,907.204 rows=105,239 loops=1)

  • Hash Cond: (v.id_utilisateur_creation = u3.id_utilisateur)
10. 101.880 4,797.065 ↓ 1.3 105,239 1

Hash Join (cost=211,514.70..250,019.27 rows=83,818 width=621) (actual time=3,261.051..4,797.065 rows=105,239 loops=1)

  • Hash Cond: (t.id_utilisateur_creation = u.id_utilisateur)
11. 74.868 4,692.683 ↓ 1.3 105,239 1

Hash Join (cost=211,330.79..248,263.77 rows=83,818 width=612) (actual time=3,258.519..4,692.683 rows=105,239 loops=1)

  • Hash Cond: (tt.id_ticketing_queue = tq.id_ticketing_queue)
12. 79.133 4,617.786 ↓ 1.3 105,239 1

Hash Join (cost=211,329.49..247,109.98 rows=83,818 width=485) (actual time=3,258.472..4,617.786 rows=105,239 loops=1)

  • Hash Cond: (t.id_ticketing_thematique = tt.id_ticketing_thematique)
13. 69.297 4,538.615 ↓ 1.3 105,239 1

Hash Join (cost=211,327.08..245,955.06 rows=83,818 width=463) (actual time=3,258.415..4,538.615 rows=105,239 loops=1)

  • Hash Cond: (t.id_ticketing_statut = ts.id_ticketing_statut)
14. 82.633 4,469.289 ↓ 1.3 105,239 1

Hash Join (cost=211,325.72..244,801.20 rows=83,818 width=340) (actual time=3,258.354..4,469.289 rows=105,239 loops=1)

  • Hash Cond: (v.id_statut_vente = sv.id_statut_vente)
15. 882.274 4,386.535 ↓ 1.3 105,239 1

Hash Join (cost=211,319.25..243,642.24 rows=83,818 width=301) (actual time=3,258.218..4,386.535 rows=105,239 loops=1)

  • Hash Cond: (ams.id_adresse_manager = sa.id_address_manager)
16. 337.599 337.599 ↑ 1.0 623,768 1

Seq Scan on adresse_manager ams (cost=0.00..16,368.68 rows=623,768 width=37) (actual time=0.004..337.599 rows=623,768 loops=1)

17. 93.026 3,166.662 ↓ 1.3 105,239 1

Hash (cost=207,242.53..207,242.53 rows=83,818 width=272) (actual time=3,166.662..3,166.662 rows=105,239 loops=1)

  • Buckets: 4096 Batches: 4 Memory Usage: 5718kB
18. 165.251 3,073.636 ↓ 1.3 105,239 1

Hash Join (cost=179,561.01..207,242.53 rows=83,818 width=272) (actual time=2,439.311..3,073.636 rows=105,239 loops=1)

  • Hash Cond: (v.id_client = c.id_client)
19. 472.449 2,250.549 ↓ 1.0 105,252 1

Hash Join (cost=140,302.86..157,140.62 rows=104,295 width=252) (actual time=1,780.981..2,250.549 rows=105,252 loops=1)

  • Hash Cond: (sa.id_sale = v.id_vente)
20. 133.825 133.825 ↑ 1.0 426,386 1

Seq Scan on sale_address sa (cost=0.00..7,399.86 rows=426,386 width=8) (actual time=0.019..133.825 rows=426,386 loops=1)

21. 85.445 1,644.275 ↓ 1.0 105,253 1

Hash (cost=135,534.95..135,534.95 rows=104,313 width=248) (actual time=1,644.275..1,644.275 rows=105,253 loops=1)

  • Buckets: 4096 Batches: 4 Memory Usage: 5068kB
22. 222.884 1,558.830 ↓ 1.0 105,253 1

Hash Join (cost=18,368.33..135,534.95 rows=104,313 width=248) (actual time=335.612..1,558.830 rows=105,253 loops=1)

  • Hash Cond: (t.id_vente = v.id_vente)
23. 1,000.956 1,000.956 ↓ 1.0 105,253 1

Seq Scan on ticket t (cost=0.00..106,448.27 rows=104,355 width=228) (actual time=0.019..1,000.956 rows=105,253 loops=1)

  • Filter: (id_ticketing_thematique = ANY ('{320,321,322}'::integer[]))
  • Rows Removed by Filter: 2014912
24. 136.154 334.990 ↑ 1.0 426,459 1

Hash (cost=10,538.59..10,538.59 rows=426,459 width=20) (actual time=334.990..334.990 rows=426,459 loops=1)

  • Buckets: 32768 Batches: 4 Memory Usage: 5332kB
25. 198.836 198.836 ↑ 1.0 426,459 1

Seq Scan on vente v (cost=0.00..10,538.59 rows=426,459 width=20) (actual time=0.009..198.836 rows=426,459 loops=1)

26. 159.725 657.836 ↓ 1.0 335,306 1

Hash (cost=33,108.03..33,108.03 rows=334,970 width=24) (actual time=657.836..657.836 rows=335,306 loops=1)

  • Buckets: 32768 Batches: 2 Memory Usage: 9519kB
27. 498.111 498.111 ↓ 1.0 335,306 1

Seq Scan on client c (cost=0.00..33,108.03 rows=334,970 width=24) (actual time=0.047..498.111 rows=335,306 loops=1)

  • Filter: (id_type_client <> 3)
  • Rows Removed by Filter: 81496
28. 0.045 0.121 ↑ 1.0 154 1

Hash (cost=4.54..4.54 rows=154 width=43) (actual time=0.121..0.121 rows=154 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 12kB
29. 0.076 0.076 ↑ 1.0 154 1

Seq Scan on statut_vente sv (cost=0.00..4.54 rows=154 width=43) (actual time=0.003..0.076 rows=154 loops=1)

30. 0.006 0.029 ↑ 1.0 16 1

Hash (cost=1.16..1.16 rows=16 width=123) (actual time=0.029..0.029 rows=16 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 1kB
31. 0.023 0.023 ↑ 1.0 16 1

Seq Scan on ticketing_statut ts (cost=0.00..1.16 rows=16 width=123) (actual time=0.020..0.023 rows=16 loops=1)

32. 0.021 0.038 ↑ 1.0 63 1

Hash (cost=1.63..1.63 rows=63 width=30) (actual time=0.038..0.038 rows=63 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 4kB
33. 0.017 0.017 ↑ 1.0 63 1

Seq Scan on ticketing_thematique tt (cost=0.00..1.63 rows=63 width=30) (actual time=0.006..0.017 rows=63 loops=1)

34. 0.002 0.029 ↑ 1.0 13 1

Hash (cost=1.13..1.13 rows=13 width=135) (actual time=0.029..0.029 rows=13 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 1kB
35. 0.027 0.027 ↑ 1.0 13 1

Seq Scan on ticketing_queue tq (cost=0.00..1.13 rows=13 width=135) (actual time=0.021..0.027 rows=13 loops=1)

36. 1.264 2.502 ↑ 1.0 4,663 1

Hash (cost=125.63..125.63 rows=4,663 width=17) (actual time=2.502..2.502 rows=4,663 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 221kB
37. 1.238 1.238 ↑ 1.0 4,663 1

Seq Scan on utilisateur u (cost=0.00..125.63 rows=4,663 width=17) (actual time=0.003..1.238 rows=4,663 loops=1)

38. 1.160 3.407 ↑ 1.0 4,663 1

Hash (cost=125.63..125.63 rows=4,663 width=8) (actual time=3.407..3.407 rows=4,663 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 166kB
39. 2.247 2.247 ↑ 1.0 4,663 1

Seq Scan on utilisateur u3 (cost=0.00..125.63 rows=4,663 width=8) (actual time=0.028..2.247 rows=4,663 loops=1)

40. 1,683.824 1,683.824 ↑ 1.0 1 105,239

Index Scan using ticketing_history_pkey on ticketing_history thi (cost=0.43..3.65 rows=1 width=20) (actual time=0.015..0.016 rows=1 loops=105,239)

  • Index Cond: (id_ticketing_history = t.last_id_ticketing_history)
  • Filter: (id_ticket = t.id_ticket)
41. 1.187 2.356 ↑ 1.0 4,663 1

Hash (cost=125.63..125.63 rows=4,663 width=13) (actual time=2.356..2.356 rows=4,663 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 219kB
42. 1.169 1.169 ↑ 1.0 4,663 1

Seq Scan on utilisateur thu (cost=0.00..125.63 rows=4,663 width=13) (actual time=0.011..1.169 rows=4,663 loops=1)

43. 0.005 0.042 ↑ 1.0 34 1

Hash (cost=1.34..1.34 rows=34 width=422) (actual time=0.042..0.042 rows=34 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 2kB
44. 0.037 0.037 ↑ 1.0 34 1

Seq Scan on ticketing_detail td (cost=0.00..1.34 rows=34 width=422) (actual time=0.027..0.037 rows=34 loops=1)

45. 0.061 3.193 ↑ 1.9 234 1

Hash (cost=24,214.74..24,214.74 rows=454 width=12) (actual time=3.193..3.193 rows=234 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 11kB
46. 0.050 3.132 ↑ 1.9 234 1

Subquery Scan on cat (cost=24,205.66..24,214.74 rows=454 width=12) (actual time=3.037..3.132 rows=234 loops=1)

47. 0.301 3.082 ↑ 1.9 234 1

HashAggregate (cost=24,205.66..24,210.20 rows=454 width=4) (actual time=3.035..3.082 rows=234 loops=1)

  • Group Key: tca_1.id_ticket
48. 2.685 2.781 ↑ 30.8 247 1

Bitmap Heap Scan on ticketing_callback_action tca_1 (cost=179.31..24,167.67 rows=7,597 width=4) (actual time=0.141..2.781 rows=247 loops=1)

  • Recheck Cond: (id_callback_action = 2060)
  • Heap Blocks: exact=240
49. 0.096 0.096 ↑ 30.8 247 1

Bitmap Index Scan on ix_ticketing_callback_action_id_vw_order_error (cost=0.00..177.41 rows=7,597 width=0) (actual time=0.096..0.096 rows=247 loops=1)

  • Index Cond: (id_callback_action = 2060)
50. 0.007 0.028 ↑ 1.0 19 1

Hash (cost=1.19..1.19 rows=19 width=520) (actual time=0.028..0.028 rows=19 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 2kB
51. 0.021 0.021 ↑ 1.0 19 1

Seq Scan on produit p (cost=0.00..1.19 rows=19 width=520) (actual time=0.019..0.021 rows=19 loops=1)

52. 0.007 0.026 ↑ 1.0 11 1

Hash (cost=1.11..1.11 rows=11 width=1,552) (actual time=0.026..0.026 rows=11 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 2kB
53. 0.019 0.019 ↑ 1.0 11 1

Seq Scan on follow_up fu (cost=0.00..1.11 rows=11 width=1,552) (actual time=0.018..0.019 rows=11 loops=1)

54. 0.000 420.956 ↑ 1.0 1 105,239

Index Scan using id_chasing_action_pkey on ticketing_callback_action tca (cost=11.53..14.95 rows=1 width=84) (actual time=0.004..0.004 rows=1 loops=105,239)

  • Index Cond: (id_ticketing_callback_action = (SubPlan 1))
55.          

SubPlan (forIndex Scan)

56. 210.478 1,789.063 ↑ 1.0 1 105,239

Aggregate (cost=11.09..11.10 rows=1 width=4) (actual time=0.017..0.017 rows=1 loops=105,239)

57. 1,578.585 1,578.585 ↑ 12.0 1 105,239

Index Scan using ix_ticketing_callback_action_id_ticket on ticketing_callback_action (cost=0.43..11.06 rows=12 width=4) (actual time=0.013..0.015 rows=1 loops=105,239)

  • Index Cond: (id_ticket = t.id_ticket)
  • Filter: (id_callback_action <> ALL ('{60,62}'::integer[]))
  • Rows Removed by Filter: 1
58. 210.478 1,789.063 ↑ 1.0 1 105,239

Aggregate (cost=11.09..11.10 rows=1 width=4) (actual time=0.017..0.017 rows=1 loops=105,239)

59. 1,578.585 1,578.585 ↑ 12.0 1 105,239

Index Scan using ix_ticketing_callback_action_id_ticket on ticketing_callback_action (cost=0.43..11.06 rows=12 width=4) (actual time=0.013..0.015 rows=1 loops=105,239)

  • Index Cond: (id_ticket = t.id_ticket)
  • Filter: (id_callback_action <> ALL ('{60,62}'::integer[]))
  • Rows Removed by Filter: 1
60. 0.083 0.171 ↑ 1.0 178 1

Hash (cost=5.78..5.78 rows=178 width=62) (actual time=0.171..0.171 rows=178 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 17kB
61. 0.088 0.088 ↑ 1.0 178 1

Seq Scan on callback_action ca (cost=0.00..5.78 rows=178 width=62) (actual time=0.018..0.088 rows=178 loops=1)