explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Jegm

Settings
# exclusive inclusive rows x rows loops node
1. 0.090 10,792.854 ↑ 1.0 1 1

Aggregate (cost=7,986.12..7,986.13 rows=1 width=8) (actual time=10,792.854..10,792.854 rows=1 loops=1)

2. 0.500 10,792.764 ↓ 221.0 442 1

Unique (cost=7,985.96..7,986.09 rows=2 width=1,466) (actual time=10,792.126..10,792.764 rows=442 loops=1)

3. 2.244 10,792.264 ↓ 221.0 442 1

Sort (cost=7,985.96..7,985.96 rows=2 width=1,466) (actual time=10,792.122..10,792.264 rows=442 loops=1)

  • Sort Key: (COALESCE(eil2.id, eil1.id)), eil1.id, eil1.hareket_kod, (COALESCE(eil2.islem_yapma_tarih, eil1.islem_yapma_tarih)), eil1.islem_yapilan_birim, eil1.ukullanici_birim_id, eil1.evrak_hareket_id, e.olusturan_tipi, e.id, e.evrak_no, e.belge_tarih, e.tarih, e.evrak_sayi, e.konu_ozet, e.evrak_turu, e.evrak_gelis_tipi, eil2.islem_yapilan_birim, eil2.islem_yapan_klncbrm, eil2.ukullanici_birim_id, ((SubPlan 12)), ((SubPlan 13)), ((SubPlan 14)), ((SubPlan 15)), (CASE WHEN (e.olusturan_tipi = 'K'::bpchar) THEN ((SubPlan 16))::text WHEN (e.olusturan_tipi = 'D'::bpchar) THEN (SubPlan 17) WHEN (e.olusturan_tipi = 'T'::bpchar) THEN ((SubPlan 18))::text WHEN (e.olusturan_tipi = 'G'::bpchar) THEN (SubPlan 19) WHEN (e.olusturan_tipi = 'B'::bpchar) THEN ((SubPlan 20))::text ELSE NULL::text END), ((SubPlan 21)),eil2.id
  • Sort Method: quicksort Memory: 249kB
4. 0.187 10,790.020 ↓ 221.0 442 1

Append (cost=1,537.96..7,985.95 rows=2 width=1,466) (actual time=5,617.391..10,790.020 rows=442 loops=1)

5. 18.896 10,155.555 ↓ 442.0 442 1

Nested Loop Left Join (cost=1,537.96..3,735.86 rows=1 width=356) (actual time=5,617.389..10,155.555 rows=442 loops=1)

  • Filter: ((COALESCE(eil2.islem_yapma_tarih, eil1.islem_yapma_tarih) >= '2020-06-01 00:00:00'::timestamp without time zone) AND (COALESCE(eil2.islem_yapma_tarih, eil1.islem_yapma_tarih) <= '2020-06-23 23:59:00'::timestamp without time zone))
  • Rows Removed by Filter: 20,406
6. 37.109 8,837.104 ↓ 20,820.0 20,820 1

Nested Loop (cost=1,537.53..3,599.04 rows=1 width=162) (actual time=246.421..8,837.104 rows=20,820 loops=1)

7. 87.030 8,633.435 ↓ 20,820.0 20,820 1

Bitmap Heap Scan on evrak_islem_log eil1 (cost=1,537.10..3,590.59 rows=1 width=46) (actual time=246.383..8,633.435 rows=20,820 loops=1)

  • Recheck Cond: ((islem_yapilan_birim = '9055'::numeric) AND ((hareket_kod)::text = 'EVRKAYIT'::text) AND (ukullanici_birim_id = '4178'::numeric))
  • Filter: ((hareket_durum = ANY ('{Y,I}'::bpchar[])) AND ((SubPlan 22) = 0))
  • Heap Blocks: exact=16,232
8. 13.690 239.225 ↓ 0.0 0 1

BitmapAnd (cost=1,537.10..1,537.10 rows=117 width=0) (actual time=239.225..239.225 rows=0 loops=1)

9. 142.800 142.800 ↓ 4.2 92,924 1

Bitmap Index Scan on evrak_islem_log_x3 (cost=0.00..671.66 rows=21,910 width=0) (actual time=142.800..142.800 rows=92,924 loops=1)

  • Index Cond: ((islem_yapilan_birim = '9055'::numeric) AND ((hareket_kod)::text = 'EVRKAYIT'::text))
10. 82.735 82.735 ↑ 1.0 43,503 1

Bitmap Index Scan on evrak_islem_log_ukullanici_birim_id_idx (cost=0.00..865.19 rows=44,901 width=0) (actual time=82.735..82.735 rows=43,503 loops=1)

  • Index Cond: (ukullanici_birim_id = '4178'::numeric)
11.          

SubPlan (for Bitmap Heap Scan)

12. 20.820 8,307.180 ↑ 1.0 1 20,820

Aggregate (cost=13.60..13.61 rows=1 width=8) (actual time=0.399..0.399 rows=1 loops=20,820)

13. 20.820 8,286.360 ↓ 0.0 0 20,820

Bitmap Heap Scan on evrak_islem_log ehh_3 (cost=9.58..13.60 rows=1 width=6) (actual time=0.398..0.398 rows=0 loops=20,820)

  • Recheck Cond: ((evrak_id = eil1.evrak_id) AND (geri_gonderilen_birim = eil1.islem_yapilan_birim) AND ((hareket_kod)::text = 'IADEETME'::text))
  • Filter: menu_aktif
  • Rows Removed by Filter: 0
  • Heap Blocks: exact=365
14. 62.460 8,265.540 ↓ 0.0 0 20,820

BitmapAnd (cost=9.58..9.58 rows=1 width=0) (actual time=0.397..0.397 rows=0 loops=20,820)

15. 624.600 624.600 ↑ 1.9 11 20,820

Bitmap Index Scan on ix_eil_onceki_hareket_id (cost=0.00..4.59 rows=21 width=0) (actual time=0.030..0.030 rows=11 loops=20,820)

  • Index Cond: (evrak_id = eil1.evrak_id)
16. 7,578.480 7,578.480 ↓ 96.1 1,729 20,820

Bitmap Index Scan on evrak_islem_log_x4 (cost=0.00..4.74 rows=18 width=0) (actual time=0.364..0.364 rows=1,729 loops=20,820)

  • Index Cond: ((geri_gonderilen_birim = eil1.islem_yapilan_birim) AND ((hareket_kod)::text = 'IADEETME'::text))
17. 166.560 166.560 ↑ 1.0 1 20,820

Index Scan using evrak_pkey on evrak e (cost=0.42..8.45 rows=1 width=116) (actual time=0.008..0.008 rows=1 loops=20,820)

  • Index Cond: (id = eil1.evrak_id)
  • Filter: ((orj_evrak_id IS NULL) AND (evrak_tipi = '1'::bpchar))
18. 957.720 957.720 ↑ 1.0 1 20,820

Index Scan using evrak_islem_log_onceki_hareket_id_idx on evrak_islem_log eil2 (cost=0.43..8.46 rows=1 width=40) (actual time=0.045..0.046 rows=1 loops=20,820)

  • Index Cond: (onceki_hareket_id = eil1.evrak_hareket_id)
  • Filter: ((isleme_sunan_birim = '9055'::numeric) AND ((hareket_kod)::text = 'HAVALEETME'::text) AND (isleme_sunan_birim = eil1.islem_yapilan_birim) AND (hareket_durum = ANY ('{Y,I,G}'::bpchar[])))
  • Rows Removed by Filter: 0
19.          

SubPlan (for Nested Loop Left Join)

20. 15.470 15.470 ↑ 1.0 1 442

Seq Scan on birim birim_1 (cost=0.00..7.38 rows=1 width=37) (actual time=0.011..0.035 rows=1 loops=442)

  • Filter: (birim_id = eil2.islem_yapilan_birim)
  • Rows Removed by Filter: 91
21. 0.866 0.884 ↓ 0.0 0 442

Nested Loop (cost=0.56..16.61 rows=1 width=32) (actual time=0.002..0.002 rows=0 loops=442)

22. 0.000 0.000 ↓ 0.0 0 442

Index Scan using kullanici_birim_pkey on kullanici_birim kb_4 (cost=0.28..8.30 rows=1 width=8) (actual time=0.000..0.000 rows=0 loops=442)

  • Index Cond: (id = eil2.islem_yapan_klncbrm)
23. 0.018 0.018 ↑ 1.0 1 3

Index Scan using kullanici_pkey on kullanici kullanici_4 (cost=0.28..8.29 rows=1 width=22) (actual time=0.006..0.006 rows=1 loops=3)

  • Index Cond: (id = kb_4.kullanici_id)
24. 4.420 8.840 ↑ 1.0 1 442

Nested Loop (cost=0.56..16.61 rows=1 width=32) (actual time=0.019..0.020 rows=1 loops=442)

25. 2.210 2.210 ↑ 1.0 1 442

Index Scan using kullanici_birim_pkey on kullanici_birim kb_5 (cost=0.28..8.30 rows=1 width=8) (actual time=0.005..0.005 rows=1 loops=442)

  • Index Cond: (id = eil2.ukullanici_birim_id)
26. 2.210 2.210 ↑ 1.0 1 442

Index Scan using kullanici_pkey on kullanici kullanici_5 (cost=0.28..8.29 rows=1 width=22) (actual time=0.005..0.005 rows=1 loops=442)

  • Index Cond: (id = kb_5.kullanici_id)
27. 1.768 5.304 ↑ 1.0 1 442

Nested Loop (cost=0.56..16.61 rows=1 width=32) (actual time=0.012..0.012 rows=1 loops=442)

28. 1.768 1.768 ↑ 1.0 1 442

Index Scan using kullanici_birim_pkey on kullanici_birim kb_6 (cost=0.28..8.30 rows=1 width=8) (actual time=0.004..0.004 rows=1 loops=442)

  • Index Cond: (id = eil1.ukullanici_birim_id)
29. 1.768 1.768 ↑ 1.0 1 442

Index Scan using kullanici_pkey on kullanici kullanici_6 (cost=0.28..8.29 rows=1 width=22) (actual time=0.003..0.004 rows=1 loops=442)

  • Index Cond: (id = kb_6.kullanici_id)
30. 0.072 0.204 ↑ 1.0 1 6

Nested Loop (cost=0.56..16.61 rows=1 width=32) (actual time=0.032..0.034 rows=1 loops=6)

31. 0.054 0.054 ↑ 1.0 1 6

Index Scan using kullanici_birim_pkey on kullanici_birim kb_7 (cost=0.28..8.30 rows=1 width=8) (actual time=0.009..0.009 rows=1 loops=6)

  • Index Cond: (id = e.referans_id)
32. 0.078 0.078 ↑ 1.0 1 6

Index Scan using kullanici_pkey on kullanici kullanici_7 (cost=0.28..8.29 rows=1 width=22) (actual time=0.012..0.013 rows=1 loops=6)

  • Index Cond: (id = kb_7.kullanici_id)
33. 0.549 40.809 ↑ 1.0 1 183

Nested Loop Left Join (cost=0.84..16.89 rows=1 width=32) (actual time=0.222..0.223 rows=1 loops=183)

34. 24.705 24.705 ↑ 1.0 1 183

Index Scan using pk_dtvt on dtvt d_1 (cost=0.42..8.44 rows=1 width=45) (actual time=0.134..0.135 rows=1 loops=183)

  • Index Cond: (dtvt_birim_id = e.referans_id)
35. 15.555 15.555 ↑ 1.0 1 183

Index Scan using pk_dtvt on dtvt par_1 (cost=0.42..8.44 rows=1 width=45) (actual time=0.085..0.085 rows=1 loops=183)

  • Index Cond: (dtvt_birim_id = d_1.parent_dtvt_birim_id)
36. 2.160 2.160 ↑ 1.0 1 240

Index Scan using tuzel_kisi_pkey on tuzel_kisi t_1 (cost=0.29..8.31 rows=1 width=49) (actual time=0.009..0.009 rows=1 loops=240)

  • Index Cond: (id = e.referans_id)
37. 6.942 6.942 ↑ 1.0 1 13

Index Scan using gercek_kisi_pkey on gercek_kisi g_1 (cost=0.29..8.31 rows=1 width=32) (actual time=0.534..0.534 rows=1 loops=13)

  • Index Cond: (id = e.referans_id)
38. 0.000 0.000 ↓ 0.0 0

Seq Scan on birim b_1 (cost=0.00..7.38 rows=1 width=37) (never executed)

  • Filter: (birim_id = e.referans_id)
39. 1.326 261.222 ↑ 1.0 1 442

Aggregate (cost=13.60..13.61 rows=1 width=8) (actual time=0.590..0.591 rows=1 loops=442)

40. 0.884 259.896 ↓ 0.0 0 442

Bitmap Heap Scan on evrak_islem_log ehh_2 (cost=9.58..13.60 rows=1 width=6) (actual time=0.588..0.588 rows=0 loops=442)

  • Recheck Cond: ((evrak_id = eil1.evrak_id) AND (geri_gonderilen_birim = eil1.islem_yapilan_birim) AND ((hareket_kod)::text = 'IADEETME'::text))
  • Filter: menu_aktif
  • Rows Removed by Filter: 0
  • Heap Blocks: exact=5
41. 1.326 259.012 ↓ 0.0 0 442

BitmapAnd (cost=9.58..9.58 rows=1 width=0) (actual time=0.586..0.586 rows=0 loops=442)

42. 4.420 4.420 ↑ 2.6 8 442

Bitmap Index Scan on ix_eil_onceki_hareket_id (cost=0.00..4.59 rows=21 width=0) (actual time=0.010..0.010 rows=8 loops=442)

  • Index Cond: (evrak_id = eil1.evrak_id)
43. 253.266 253.266 ↓ 96.1 1,729 442

Bitmap Index Scan on evrak_islem_log_x4 (cost=0.00..4.74 rows=18 width=0) (actual time=0.573..0.573 rows=1,729 loops=442)

  • Index Cond: ((geri_gonderilen_birim = eil1.islem_yapilan_birim) AND ((hareket_kod)::text = 'IADEETME'::text))
44. 0.014 634.278 ↓ 0.0 0 1

Nested Loop Left Join (cost=1,893.76..4,250.07 rows=1 width=356) (actual time=634.278..634.278 rows=0 loops=1)

  • Filter: ((COALESCE(eil2_1.islem_yapma_tarih, eil1_1.islem_yapma_tarih) >= '2020-06-01 00:00:00'::timestamp without time zone) AND (COALESCE(eil2_1.islem_yapma_tarih, eil1_1.islem_yapma_tarih) <= '2020-06-23 23:59:00'::timestamp without time zone))
  • Rows Removed by Filter: 2
45. 0.022 634.208 ↓ 2.0 2 1

Nested Loop (cost=1,893.33..4,118.39 rows=1 width=162) (actual time=22.835..634.208 rows=2 loops=1)

46. 1.350 634.144 ↓ 2.0 2 1

Bitmap Heap Scan on evrak_islem_log eil1_1 (cost=1,892.90..4,109.93 rows=1 width=52) (actual time=22.806..634.144 rows=2 loops=1)

  • Recheck Cond: ((ukullanici_birim_id = '4178'::numeric) AND (islem_yapilan_birim = '9055'::numeric) AND ((hareket_kod)::text = 'TESLIMALMA'::text))
  • Filter: ((hareket_durum = ANY ('{Y,I}'::bpchar[])) AND ((SubPlan 11) = 0))
  • Rows Removed by Filter: 174
  • Heap Blocks: exact=157
47. 2.393 10.986 ↓ 0.0 0 1

BitmapAnd (cost=1,892.90..1,892.90 rows=179 width=0) (actual time=10.986..10.986 rows=0 loops=1)

48. 7.757 7.757 ↑ 1.0 43,503 1

Bitmap Index Scan on evrak_islem_log_ukullanici_birim_id_idx (cost=0.00..865.19 rows=44,901 width=0) (actual time=7.757..7.757 rows=43,503 loops=1)

  • Index Cond: (ukullanici_birim_id = '4178'::numeric)
49. 0.836 0.836 ↑ 10.0 3,335 1

Bitmap Index Scan on evrak_islem_log_x3 (cost=0.00..1,027.46 rows=33,490 width=0) (actual time=0.836..0.836 rows=3,335 loops=1)

  • Index Cond: ((islem_yapilan_birim = '9055'::numeric) AND ((hareket_kod)::text = 'TESLIMALMA'::text))
50.          

SubPlan (for Bitmap Heap Scan)

51. 0.528 621.808 ↑ 1.0 1 176

Aggregate (cost=8.46..8.47 rows=1 width=8) (actual time=3.533..3.533 rows=1 loops=176)

52. 621.280 621.280 ↑ 1.0 1 176

Index Scan using "evrak$hareket_pkey" on "evrak$hareket" ehh_1 (cost=0.43..8.46 rows=1 width=6) (actual time=3.529..3.530 rows=1 loops=176)

  • Index Cond: (id = eil1_1.onceki_hareket_id)
  • Filter: ((hareket_kod)::text = 'IADEETME'::text)
  • Rows Removed by Filter: 0
53. 0.042 0.042 ↑ 1.0 1 2

Index Scan using evrak_pkey on evrak e_1 (cost=0.42..8.45 rows=1 width=116) (actual time=0.021..0.021 rows=1 loops=2)

  • Index Cond: (id = eil1_1.evrak_id)
  • Filter: (evrak_tipi = '1'::bpchar)
54. 0.056 0.056 ↑ 1.0 1 2

Index Scan using evrak_islem_log_onceki_hareket_id_idx on evrak_islem_log eil2_1 (cost=0.43..8.46 rows=1 width=40) (actual time=0.026..0.028 rows=1 loops=2)

  • Index Cond: (onceki_hareket_id = eil1_1.evrak_hareket_id)
  • Filter: ((isleme_sunan_birim = '9055'::numeric) AND ((hareket_kod)::text = 'HAVALEETME'::text) AND (isleme_sunan_birim = eil1_1.islem_yapilan_birim) AND (hareket_durum = ANY('{Y,I,G}'::bpchar[])))
55.          

SubPlan (for Nested Loop Left Join)

56. 0.000 0.000 ↓ 0.0 0

Seq Scan on birim (cost=0.00..7.38 rows=1 width=37) (never executed)

  • Filter: (birim_id = eil2_1.islem_yapilan_birim)
57. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=0.56..16.61 rows=1 width=32) (never executed)

58. 0.000 0.000 ↓ 0.0 0

Index Scan using kullanici_birim_pkey on kullanici_birim kb (cost=0.28..8.30 rows=1 width=8) (never executed)

  • Index Cond: (id = eil2_1.islem_yapan_klncbrm)
59. 0.000 0.000 ↓ 0.0 0

Index Scan using kullanici_pkey on kullanici (cost=0.28..8.29 rows=1 width=22) (never executed)

  • Index Cond: (id = kb.kullanici_id)
60. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=0.56..16.61 rows=1 width=32) (never executed)

61. 0.000 0.000 ↓ 0.0 0

Index Scan using kullanici_birim_pkey on kullanici_birim kb_1 (cost=0.28..8.30 rows=1 width=8) (never executed)

  • Index Cond: (id = eil2_1.ukullanici_birim_id)
62. 0.000 0.000 ↓ 0.0 0

Index Scan using kullanici_pkey on kullanici kullanici_1 (cost=0.28..8.29 rows=1 width=22) (never executed)

  • Index Cond: (id = kb_1.kullanici_id)
63. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=0.56..16.61 rows=1 width=32) (never executed)

64. 0.000 0.000 ↓ 0.0 0

Index Scan using kullanici_birim_pkey on kullanici_birim kb_2 (cost=0.28..8.30 rows=1 width=8) (never executed)

  • Index Cond: (id = eil1_1.ukullanici_birim_id)
65. 0.000 0.000 ↓ 0.0 0

Index Scan using kullanici_pkey on kullanici kullanici_2 (cost=0.28..8.29 rows=1 width=22) (never executed)

  • Index Cond: (id = kb_2.kullanici_id)
66. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=0.56..16.61 rows=1 width=32) (never executed)

67. 0.000 0.000 ↓ 0.0 0

Index Scan using kullanici_birim_pkey on kullanici_birim kb_3 (cost=0.28..8.30 rows=1 width=8) (never executed)

  • Index Cond: (id = e_1.referans_id)
68. 0.000 0.000 ↓ 0.0 0

Index Scan using kullanici_pkey on kullanici kullanici_3 (cost=0.28..8.29 rows=1 width=22) (never executed)

  • Index Cond: (id = kb_3.kullanici_id)
69. 0.000 0.000 ↓ 0.0 0

Nested Loop Left Join (cost=0.84..16.89 rows=1 width=32) (never executed)

70. 0.000 0.000 ↓ 0.0 0

Index Scan using pk_dtvt on dtvt d (cost=0.42..8.44 rows=1 width=45) (never executed)

  • Index Cond: (dtvt_birim_id = e_1.referans_id)
71. 0.000 0.000 ↓ 0.0 0

Index Scan using pk_dtvt on dtvt par (cost=0.42..8.44 rows=1 width=45) (never executed)

  • Index Cond: (dtvt_birim_id = d.parent_dtvt_birim_id)
72. 0.000 0.000 ↓ 0.0 0

Index Scan using tuzel_kisi_pkey on tuzel_kisi t (cost=0.29..8.31 rows=1 width=49) (never executed)

  • Index Cond: (id = e_1.referans_id)
73. 0.000 0.000 ↓ 0.0 0

Index Scan using gercek_kisi_pkey on gercek_kisi g (cost=0.29..8.31 rows=1 width=32) (never executed)

  • Index Cond: (id = e_1.referans_id)
74. 0.000 0.000 ↓ 0.0 0

Seq Scan on birim b (cost=0.00..7.38 rows=1 width=37) (never executed)

  • Filter: (birim_id = e_1.referans_id)
75. 0.000 0.000 ↓ 0.0 0

Aggregate (cost=8.46..8.47 rows=1 width=8) (never executed)

76. 0.000 0.000 ↓ 0.0 0

Index Scan using "evrak$hareket_pkey" on "evrak$hareket" ehh (cost=0.43..8.46 rows=1 width=6) (never executed)

  • Index Cond: (id = eil1_1.onceki_hareket_id)
  • Filter: ((hareket_kod)::text = 'IADEETME'::text)
Planning time : 18.260 ms
Execution time : 10,795.603 ms