explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 6kHG

Settings
# exclusive inclusive rows x rows loops node
1. 0.037 1,692,158.093 ↓ 1.1 12 1

Sort (cost=6,621,034.940..6,621,034.960 rows=11 width=512) (actual time=1,692,158.092..1,692,158.093 rows=12 loops=1)

  • Sort Key: mike_kilo.kilo_quebec DESC, mike_kilo.golf_three, mike_kilo.two_juliet_foxtrot
  • Sort Method: quicksort Memory: 28kB
  • Buffers: shared hit=1085419 read=799289, temp read=347 written=299
2. 0.036 1,692,158.056 ↓ 1.1 12 1

Aggregate (cost=6,621,034.640..6,621,034.750 rows=11 width=512) (actual time=1,692,158.050..1,692,158.056 rows=12 loops=1)

  • Buffers: shared hit=1085416 read=799289, temp read=347 written=299
3. 0.004 1,692,158.020 ↓ 1.1 12 1

Append (cost=4,930,517.550..6,621,034.030 rows=11 width=512) (actual time=1,692,154.103..1,692,158.020 rows=12 loops=1)

  • Buffers: shared hit=1085416 read=799289, temp read=347 written=299
4. 0.005 1,692,158.011 ↓ 1.1 11 1

Result (cost=4,930,517.550..6,621,033.910 rows=10 width=211) (actual time=1,692,154.103..1,692,158.011 rows=11 loops=1)

  • Buffers: shared hit=1085416 read=799289, temp read=347 written=299
5.          

Initplan (for Result)

6. 0.001 0.003 ↑ 1.0 1 1

Aggregate (cost=12.970..12.980 rows=1 width=8) (actual time=0.003..0.003 rows=1 loops=1)

7. 0.001 0.002 ↓ 0.0 0 1

Hash Join (cost=2.730..12.960 rows=6 width=0) (actual time=0.002..0.002 rows=0 loops=1)

8. 0.001 0.001 ↓ 0.0 0 1

Seq Scan on tango_mike tango_mike (cost=0.000..10.100 rows=10 width=18) (actual time=0.001..0.001 rows=0 loops=1)

9. 0.000 0.000 ↓ 0.0 0

Hash (cost=2.650..2.650 rows=6 width=4) (never executed)

10. 0.000 0.000 ↓ 0.0 0

Seq Scan on hotel_two kilo_oscar (cost=0.000..2.650 rows=6 width=4) (never executed)

  • Filter: (sierra1.quebec_zulu = 3001.000000000000000)
11. 0.037 1,692,158.003 ↓ 1.1 11 1

Nested Loop (cost=4,930,517.550..6,621,033.910 rows=10 width=211) (actual time=1,692,154.097..1,692,158.003 rows=11 loops=1)

  • Buffers: shared hit=1085416 read=799289, temp read=347 written=299
12. 0.010 1,692,157.900 ↓ 1.1 11 1

Nested Loop (cost=4,930,504.280..6,620,970.220 rows=10 width=164) (actual time=1,692,154.066..1,692,157.900 rows=11 loops=1)

  • Buffers: shared hit=1085372 read=799289, temp read=347 written=299
13. 0.489 1,692,157.780 ↓ 1.1 11 1

Hash Join (cost=4,930,503.710..6,620,874.850 rows=10 width=164) (actual time=1,692,154.015..1,692,157.780 rows=11 loops=1)

  • Buffers: shared hit=1085306 read=799289, temp read=347 written=299
14. 0.008 1,691,703.009 ↑ 74.5 11 1

Nested Loop (cost=4,856,712.650..6,544,112.920 rows=820 width=164) (actual time=1,691,699.249..1,691,703.009 rows=11 loops=1)

  • Buffers: shared hit=1042464 read=799289, temp read=347 written=299
15. 0.007 1,691,702.968 ↑ 347.0 1 1

Nested Loop (cost=4,856,712.080..5,430,416.520 rows=347 width=154) (actual time=1,691,699.216..1,691,702.968 rows=1 loops=1)

  • Buffers: shared hit=1042459 read=799289, temp read=347 written=299
16. 24.943 1,691,702.931 ↑ 613.0 1 1

Nested Loop (cost=4,856,711.510..5,425,490.040 rows=613 width=128) (actual time=1,691,699.179..1,691,702.931 rows=1 loops=1)

  • Buffers: shared hit=1042454 read=799289, temp read=347 written=299
17. 0.010 5.744 ↑ 1.0 6 1

Nested Loop (cost=0.140..18.400 rows=6 width=57) (actual time=5.681..5.744 rows=6 loops=1)

  • Buffers: shared hit=345
18. 0.070 0.070 ↑ 1.0 6 1

Index Scan using juliet_foxtrot on hotel_two romeo (cost=0.140..14.790 rows=6 width=9) (actual time=0.027..0.070 rows=6 loops=1)

  • Filter: ((romeo.quebec_zulu = 3001.000000000000000) AND (romeo.juliet_charlie = 'four_uniform'::numeric))
  • Buffers: shared hit=2
19. 0.005 5.664 ↑ 1.0 1 6

Materialize (cost=0.000..3.550 rows=1 width=59) (actual time=0.942..0.944 rows=1 loops=6)

  • Buffers: shared hit=343
20. 0.003 5.659 ↑ 1.0 1 1

Nested Loop (cost=0.000..3.540 rows=1 width=59) (actual time=5.648..5.659 rows=1 loops=1)

  • Buffers: shared hit=343
21. 0.014 0.014 ↑ 1.0 1 1

Seq Scan on victor_lima golf_papa (cost=0.000..1.510 rows=1 width=11) (actual time=0.006..0.014 rows=1 loops=1)

  • Filter: (golf_papa.quebec_zulu = 3001.000000000000000)
  • Buffers: shared hit=1
22. 0.002 5.642 ↑ 1.0 1 1

Limit (cost=0.000..2.010 rows=1 width=64) (actual time=5.641..5.642 rows=1 loops=1)

  • Buffers: shared hit=342
23. 5.640 5.640 ↑ 1.0 1 1

Result (cost=0.000..2.010 rows=1 width=64) (actual time=5.640..5.640 rows=1 loops=1)

  • Buffers: shared hit=342
24. 11.677 1,691,672.244 ↓ 11.4 23,865 6

Materialize (cost=4,856,711.360..5,425,288.590 rows=2,092 width=71) (actual time=281,941.529..281,945.374 rows=23,865 loops=6)

  • Buffers: shared hit=1042109 read=799289, temp read=347 written=299
25. 22.880 1,691,660.567 ↓ 11.4 23,865 1

Hash Join (cost=4,856,711.360..5,425,278.130 rows=2,092 width=71) (actual time=1,691,649.168..1,691,660.567 rows=23,865 loops=1)

  • Buffers: shared hit=1042109 read=799289, temp read=347 written=299
26. 11.619 11.619 ↑ 5.8 23,865 1

Index Scan using oscar on alpha_whiskey mike_kilo (cost=0.570..367,916.550 rows=138,905 width=71) (actual time=0.059..11.619 rows=23,865 loops=1)

  • Index Cond: (mike_kilo.four_echo = ANY ('echo_kilo'::numeric[]))
  • Buffers: shared hit=92
27. 0.000 1,691,626.068 ↓ 0.0 0 1

Hash (cost=4,044,286.270..4,044,286.270 rows=49,519,162 width=5) (actual time=1,691,626.068..1,691,626.068 rows=0 loops=1)

  • Buffers: shared hit=1042017 read=799289
28. 1,664,926.818 1,691,626.068 ↓ 0.0 0 1

Hash Join (cost=760.050..4,044,286.270 rows=49,519,162 width=5) (actual time=1,691,626.068..1,691,626.068 rows=0 loops=1)

  • Buffers: shared hit=1042017 read=799289
29. 26,690.112 26,690.112 ↓ 1.0 150,677,015 1

Seq Scan on tango_sierra hotel_tango_seven (cost=0.000..3,647,438.080 rows=150,677,008 width=13) (actual time=0.019..26,690.112 rows=150,677,015 loops=1)

  • Buffers: shared hit=1041835 read=799289
30. 5.472 9.138 ↓ 1.0 25,693 1

Hash (cost=438.910..438.910 rows=25,691 width=11) (actual time=9.138..9.138 rows=25,693 loops=1)

  • Buffers: shared hit=182
31. 3.666 3.666 ↓ 1.0 25,693 1

Seq Scan on victor_foxtrot hotel_whiskey (cost=0.000..438.910 rows=25,691 width=11) (actual time=0.004..3.666 rows=25,693 loops=1)

  • Buffers: shared hit=182
32. 0.030 0.030 ↑ 1.0 1 1

Index Scan using whiskey_whiskey on tango_sierra november (cost=0.570..8.040 rows=1 width=30) (actual time=0.030..0.030 rows=1 loops=1)

  • Index Cond: ((november.golf_three = mike_kilo.golf_three) AND (november.two_juliet_foxtrot = mike_kilo.two_juliet_foxtrot))
  • Buffers: shared hit=5
33. 0.033 0.033 ↑ 303.8 11 1

Index Scan using victor_uniform on two_juliet_juliet four_delta (cost=0.570..3,176.080 rows=3,342 width=32) (actual time=0.029..0.033 rows=11 loops=1)

  • Index Cond: ((four_delta.golf_three = november.golf_three) AND (four_delta.two_juliet_foxtrot = november.two_juliet_foxtrot))
  • Buffers: shared hit=5
34. 0.056 454.282 ↓ 0.0 0 1

Hash (cost=71,940.550..71,940.550 rows=112,761 width=6) (actual time=454.282..454.282 rows=0 loops=1)

  • Buffers: shared hit=42842
35. 454.226 454.226 ↑ 113.3 995 1

Seq Scan on hotel_tango_echo india (cost=0.000..71,940.550 rows=112,761 width=6) (actual time=453.800..454.226 rows=995 loops=1)

  • Filter: ((india.hotel_five)::text = ANY ('whiskey_juliet'::text[]))
  • Buffers: shared hit=42842
36. 0.022 0.110 ↓ 0.0 0 11

Nested Loop (cost=0.570..9.530 rows=1 width=6) (actual time=0.010..0.010 rows=0 loops=11)

  • Buffers: shared hit=66
37. 0.044 0.044 ↑ 1.0 1 11

Index Scan using juliet_kilo on victor_foxtrot yankee (cost=0.290..3.630 rows=1 width=11) (actual time=0.004..0.004 rows=1 loops=11)

  • Index Cond: (yankee.kilo_quebec = mike_kilo.kilo_quebec)
  • Buffers: shared hit=33
38. 0.044 0.044 ↓ 0.0 0 11

Index Scan using delta_five on foxtrot_juliet kilo_yankee (cost=0.280..3.650 rows=1 width=7) (actual time=0.004..0.004 rows=0 loops=11)

  • Index Cond: (kilo_yankee.alpha_lima = yankee.foxtrot_charlie)
  • Filter: ((kilo_yankee.papa)::text = ANY ('two_two'::text[]))
  • Buffers: shared hit=33
39. 0.033 0.033 ↑ 1.0 1 11

Index Scan using delta_alpha_two on victor_foxtrot quebec_tango (cost=0.290..3.620 rows=1 width=11) (actual time=0.003..0.003 rows=1 loops=11)

  • Index Cond: (delta_alpha_whiskey1.kilo_quebec = mike_kilo.kilo_quebec)
  • Buffers: shared hit=33
40.          

SubPlan (for Nested Loop)

41. 0.033 0.033 ↑ 1.0 1 11

Seq Scan on zulu mike_zulu (cost=0.000..1.440 rows=1 width=5) (actual time=0.002..0.003 rows=1 loops=11)

  • Filter: (((mike_zulu.three)::text = (four_delta.three)::text) AND ((mike_zulu.tango_zulu)::text = (november.tango_zulu)::text))
  • Buffers: shared hit=11
42. 0.004 0.005 ↑ 1.0 1 1

Subquery Scan on echo_uniform (cost=0.000..0.020 rows=1 width=512) (actual time=0.005..0.005 rows=1 loops=1)

43. 0.001 0.001 ↑ 1.0 1 1

Result (cost=0.000..0.010 rows=1 width=484) (actual time=0.001..0.001 rows=1 loops=1)

Planning time : 8.336 ms
Execution time : 1,692,160.181 ms