explain.depesz.com

PostgreSQL's explain analyze made readable

Result: u3Od : Hostdetail

Settings
# exclusive inclusive rows x rows loops node
1. 1.446 68.486 ↓ 130.4 3,000 1

Hash Join (cost=3,532.62..3,801.19 rows=23 width=512) (actual time=60.59..68.486 rows=3,000 loops=1)

  • Buffers: shared hit=1669
2. 1.347 67.023 ↓ 750.0 3,000 1

Hash Join (cost=3,496.52..3,764.27 rows=4 width=478) (actual time=60.564..67.023 rows=3,000 loops=1)

  • Buffers: shared hit=1668
3. 4.412 65.670 ↓ 750.0 3,000 1

Hash Join (cost=3,482.69..3,750.44 rows=4 width=336) (actual time=60.552..65.67 rows=3,000 loops=1)

  • Buffers: shared hit=1667
4. 0.720 0.720 ↑ 1.0 3,033 1

Seq Scan on ssm_hosts b (cost=0..256.33 rows=3,033 width=175) (actual time=0.005..0.72 rows=3,033 loops=1)

  • Buffers: shared hit=226
5. 1.944 60.538 ↓ 200.0 3,000 1

Hash (cost=3,482.51..3,482.51 rows=15 width=165) (actual time=60.538..60.538 rows=3,000 loops=1)

  • Buffers: shared hit=1441
6. 2.274 58.594 ↓ 200.0 3,000 1

Merge Join (cost=3,282.74..3,482.51 rows=15 width=165) (actual time=49.59..58.594 rows=3,000 loops=1)

  • Buffers: shared hit=1441
7. 2.189 41.511 ↓ 200.0 3,000 1

Sort (cost=2,273.48..2,273.52 rows=15 width=133) (actual time=41.171..41.511 rows=3,000 loops=1)

  • Sort Key: a.object_id
  • Sort Method: quicksort Memory: 673kB
  • Buffers: shared hit=1250
8. 1.675 39.322 ↓ 200.0 3,000 1

Hash Join (cost=2,201.14..2,273.19 rows=15 width=133) (actual time=37.006..39.322 rows=3,000 loops=1)

  • Buffers: shared hit=1250
9. 3.687 25.397 ↑ 1.0 3,000 1

Aggregate (cost=1,673.82..1,704.14 rows=3,032 width=8) (actual time=24.749..25.397 rows=3,000 loops=1)

  • Buffers: shared hit=977
10. 2.547 21.710 ↓ 1.8 8,700 1

Hash Join (cost=1,017.25..1,650.22 rows=4,720 width=8) (actual time=13.12..21.71 rows=8,700 loops=1)

  • Buffers: shared hit=977
11. 4.288 19.155 ↓ 1.8 8,700 1

Hash Join (cost=1,003.43..1,623.7 rows=4,720 width=12) (actual time=13.104..19.155 rows=8,700 loops=1)

  • Buffers: shared hit=976
12. 1.783 1.783 ↑ 1.0 8,805 1

Seq Scan on ssm_servicestatus f_1 (cost=0..540.05 rows=8,805 width=8) (actual time=0.005..1.783 rows=8,805 loops=1)

  • Buffers: shared hit=452
13. 2.421 13.084 ↓ 1.4 8,700 1

Hash (cost=923.32..923.32 rows=6,409 width=16) (actual time=13.084..13.084 rows=8,700 loops=1)

  • Buffers: shared hit=524
14. 3.748 10.663 ↓ 1.4 8,700 1

Hash Join (cost=410.14..923.32 rows=6,409 width=16) (actual time=5.263..10.663 rows=8,700 loops=1)

  • Buffers: shared hit=524
15. 1.680 1.680 ↑ 1.0 8,805 1

Seq Scan on ssm_services e_1 (cost=0..490.05 rows=8,805 width=8) (actual time=0.005..1.68 rows=8,805 loops=1)

  • Buffers: shared hit=402
16. 2.198 5.235 ↑ 1.0 8,700 1

Hash (cost=301.36..301.36 rows=8,703 width=8) (actual time=5.234..5.235 rows=8,700 loops=1)

  • Buffers: shared hit=122
17. 3.037 3.037 ↑ 1.0 8,700 1

Seq Scan on ssm_objects a_1 (cost=0..301.36 rows=8,703 width=8) (actual time=0.037..3.037 rows=8,700 loops=1)

  • Filter: ((a_1.is_active = 1) AND (a_1.objecttype_id = 2))
  • Buffers: shared hit=122
18. 0.002 0.008 ↑ 170.0 1 1

Hash (cost=11.7..11.7 rows=170 width=4) (actual time=0.008..0.008 rows=1 loops=1)

  • Buffers: shared hit=1
19. 0.006 0.006 ↑ 170.0 1 1

Seq Scan on ssm_instances d_1 (cost=0..11.7 rows=170 width=4) (actual time=0.006..0.006 rows=1 loops=1)

  • Buffers: shared hit=1
20. 1.744 12.250 ↓ 200.0 3,000 1

Hash (cost=527.12..527.12 rows=15 width=129) (actual time=12.25..12.25 rows=3,000 loops=1)

  • Buffers: shared hit=273
21. 1.805 10.506 ↓ 200.0 3,000 1

Hash Join (cost=214.38..527.12 rows=15 width=129) (actual time=6.125..10.506 rows=3,000 loops=1)

  • Buffers: shared hit=273
22. 2.628 2.628 ↓ 1.0 3,000 1

Seq Scan on ssm_objects a (cost=0..301.36 rows=2,998 width=8) (actual time=0.046..2.628 rows=3,000 loops=1)

  • Filter: ((a.is_active = 1) AND (a.objecttype_id = 1))
  • Buffers: shared hit=122
23. 1.811 6.073 ↓ 49.7 3,033 1

Hash (cost=213.61..213.61 rows=61 width=121) (actual time=6.073..6.073 rows=3,033 loops=1)

  • Buffers: shared hit=151
24. 3.551 4.262 ↓ 49.7 3,033 1

Hash Join (cost=21.3..213.61 rows=61 width=121) (actual time=0.021..4.262 rows=3,033 loops=1)

  • Buffers: shared hit=151
25. 0.702 0.702 ↑ 1.0 3,033 1

Seq Scan on ssm_hoststatus c (cost=0..180.33 rows=3,033 width=71) (actual time=0.005..0.702 rows=3,033 loops=1)

  • Buffers: shared hit=150
26. 0.002 0.009 ↑ 1.0 4 1

Hash (cost=21.25..21.25 rows=4 width=54) (actual time=0.009..0.009 rows=4 loops=1)

  • Buffers: shared hit=1
27. 0.007 0.007 ↑ 1.0 4 1

Seq Scan on ssm_tl_status e (cost=0..21.25 rows=4 width=54) (actual time=0.004..0.007 rows=4 loops=1)

  • Filter: (e.status_type = 1)
  • Buffers: shared hit=1
28. 6.109 14.809 ↑ 2.0 3,000 1

Aggregate (cost=1,009.26..1,132.1 rows=6,142 width=36) (actual time=8.413..14.809 rows=3,000 loops=1)

  • Buffers: shared hit=191
29. 1.540 8.700 ↑ 2.0 3,000 1

Sort (cost=1,009.26..1,024.61 rows=6,142 width=86) (actual time=8.396..8.7 rows=3,000 loops=1)

  • Sort Key: b_1.object_id
  • Sort Method: quicksort Memory: 237kB
  • Buffers: shared hit=191
30. 0.936 7.160 ↑ 2.0 3,000 1

Hash Join (cost=331.33..622.79 rows=6,142 width=86) (actual time=2.263..7.16 rows=3,000 loops=1)

  • Buffers: shared hit=191
31. 2.802 6.143 ↓ 1.0 3,000 1

Hash Join (cost=309.38..524.5 rows=2,996 width=8) (actual time=2.175..6.143 rows=3,000 loops=1)

  • Buffers: shared hit=188
32. 1.201 1.201 ↑ 1.0 11,811 1

Seq Scan on ssm_classification_object b_1 (cost=0..184.11 rows=11,811 width=8) (actual time=0.004..1.201 rows=11,811 loops=1)

  • Buffers: shared hit=66
33. 0.638 2.140 ↑ 1.0 3,033 1

Hash (cost=271.46..271.46 rows=3,033 width=4) (actual time=2.14..2.14 rows=3,033 loops=1)

  • Buffers: shared hit=122
34. 1.502 1.502 ↑ 1.0 3,033 1

Seq Scan on ssm_objects d_2 (cost=0..271.46 rows=3,033 width=4) (actual time=0.004..1.502 rows=3,033 loops=1)

  • Filter: (d_2.objecttype_id = 1)
  • Buffers: shared hit=122
35. 0.007 0.081 ↑ 11.7 11 1

Hash (cost=20.34..20.34 rows=129 width=86) (actual time=0.081..0.081 rows=11 loops=1)

  • Buffers: shared hit=3
36. 0.013 0.074 ↑ 11.7 11 1

Hash Join (cost=3.42..20.34 rows=129 width=86) (actual time=0.067..0.074 rows=11 loops=1)

  • Buffers: shared hit=3
37. 0.008 0.008 ↑ 34.2 12 1

Seq Scan on ssm_tl_hosttype c_1 (cost=0..14.1 rows=410 width=164) (actual time=0.007..0.008 rows=12 loops=1)

  • Buffers: shared hit=1
38. 0.033 0.053 ↑ 1.0 63 1

Hash (cost=2.63..2.63 rows=63 width=19) (actual time=0.053..0.053 rows=63 loops=1)

  • Buffers: shared hit=2
39. 0.020 0.020 ↑ 1.0 63 1

Seq Scan on ssm_classifications a_2 (cost=0..2.63 rows=63 width=19) (actual time=0.004..0.02 rows=63 loops=1)

  • Buffers: shared hit=2
40. 0.001 0.006 ↑ 170.0 1 1

Hash (cost=11.7..11.7 rows=170 width=150) (actual time=0.006..0.006 rows=1 loops=1)

  • Buffers: shared hit=1
41. 0.005 0.005 ↑ 170.0 1 1

Seq Scan on ssm_instances d (cost=0..11.7 rows=170 width=150) (actual time=0.004..0.005 rows=1 loops=1)

  • Buffers: shared hit=1
42. 0.004 0.017 ↑ 580.0 2 1

Hash (cost=21.6..21.6 rows=1,160 width=38) (actual time=0.017..0.017 rows=2 loops=1)

  • Buffers: shared hit=1
43. 0.013 0.013 ↑ 580.0 2 1

Seq Scan on ssm_tl_type f (cost=0..21.6 rows=1,160 width=38) (actual time=0.012..0.013 rows=2 loops=1)

  • Buffers: shared hit=1