explain.depesz.com

PostgreSQL's explain analyze made readable

Result: oFYj

Settings
# exclusive inclusive rows x rows loops node
1. 47.167 74,868.793 ↑ 1.0 1 1

Aggregate (cost=7,963,512,474.50..7,963,512,474.51 rows=1 width=8) (actual time=74,868.792..74,868.793 rows=1 loops=1)

2. 57,376.473 74,821.626 ↓ 1.8 100,725 1

Nested Loop Left Join (cost=41,561.91..7,963,512,335.12 rows=55,749 width=8) (actual time=434.515..74,821.626 rows=100,725 loops=1)

  • Filter: (f_unaccent(lower(dokument9_.nazov)) ~~ '%vypis%'::text)
  • Rows Removed by Filter: 4867516
3. 814.311 2,424.231 ↓ 1.2 2,503,487 1

Hash Right Join (cost=37,657.39..141,690.69 rows=2,038,087 width=24) (actual time=433.756..2,424.231 rows=2,503,487 loops=1)

  • Hash Cond: (podmienkyp7_.zonfpverzia_id = zonfpverzi1_.id)
4. 587.894 1,176.506 ↓ 1.0 1,768,194 1

Merge Left Join (cost=2.81..77,132.71 rows=1,739,340 width=16) (actual time=0.055..1,176.506 rows=1,768,194 loops=1)

  • Merge Cond: (podmienkyp7_.id = dokumenty8_.podmienkapomocidokumentzonfp_id)
5. 254.380 254.380 ↑ 1.0 756,771 1

Index Scan using d_podmienkapomocidokument_pkey on d_podmienkapomocidokumentzonfp podmienkyp7_ (cost=0.42..20,038.50 rows=756,771 width=16) (actual time=0.013..254.380 rows=756,771 loops=1)

6. 334.232 334.232 ↑ 1.0 1,739,340 1

Index Only Scan using podmienkapomocidokumentzonfp_to_dokument__dokument_id_idx on podmienkapomocidokumentzonfp_to_dokument dokumenty8_ (cost=0.43..33,460.53 rows=1,739,340 width=16) (actual time=0.039..334.232 rows=1,739,340 loops=1)

  • Heap Fetches: 0
7. 8.367 433.414 ↓ 1.1 50,329 1

Hash (cost=37,084.60..37,084.60 rows=45,599 width=24) (actual time=433.414..433.414 rows=50,329 loops=1)

  • Buckets: 65536 Batches: 1 Memory Usage: 3265kB
8. 17.743 425.047 ↓ 1.1 50,329 1

Hash Right Join (cost=34,722.63..37,084.60 rows=45,599 width=24) (actual time=399.271..425.047 rows=50,329 loops=1)

  • Hash Cond: (dokumenty5_.zonfpverzia_id = zonfpverzi1_.id)
9. 8.218 8.218 ↑ 1.0 99,489 1

Seq Scan on zonfpverzia_to_dokument dokumenty5_ (cost=0.00..1,532.89 rows=99,489 width=16) (actual time=0.015..8.218 rows=99,489 loops=1)

10. 3.323 399.086 ↓ 1.0 17,856 1

Hash (cost=34,499.68..34,499.68 rows=17,836 width=16) (actual time=399.086..399.086 rows=17,856 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 1093kB
11. 3.656 395.763 ↓ 1.0 17,856 1

Hash Left Join (cost=33,503.52..34,499.68 rows=17,836 width=16) (actual time=380.630..395.763 rows=17,856 loops=1)

  • Hash Cond: (specificke2_.specifickyciel_id = specificky3_.id)
12. 8.368 391.924 ↓ 1.0 17,856 1

Hash Right Join (cost=33,493.99..34,442.58 rows=17,836 width=24) (actual time=380.391..391.924 rows=17,856 loops=1)

  • Hash Cond: (specificke2_.zonfpverzia_id = zonfpverzi1_.id)
13. 3.306 3.306 ↑ 1.0 40,162 1

Seq Scan on zonfpverzia_to_specifickyciel specificke2_ (cost=0.00..619.62 rows=40,162 width=16) (actual time=0.024..3.306 rows=40,162 loops=1)

14. 2.815 380.250 ↑ 1.0 17,282 1

Hash (cost=33,277.97..33,277.97 rows=17,282 width=16) (actual time=380.250..380.250 rows=17,282 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 1067kB
15. 5.209 377.435 ↑ 1.0 17,282 1

Hash Join (cost=32,843.76..33,277.97 rows=17,282 width=16) (actual time=364.535..377.435 rows=17,282 loops=1)

  • Hash Cond: (zonfpverzia.id = zonfpverzi1_.id)
16. 23.241 363.650 ↑ 1.0 17,282 1

HashAggregate (cost=31,653.41..31,869.43 rows=17,282 width=632) (actual time=355.732..363.650 rows=17,282 loops=1)

  • Group Key: zonfp.id, subjektverzia.nazovuplny, subjektverzia.ico, stav.nazov, workflowst7_.vratenespat, workflowst8_.priznak, projektverzia.nazov, concat(oif.kod, ' - ', oif.nazov), faza.cislo, workflowpr9_.nazov, zonfpverzia.id, projekt.id, odoslanie.sposobodoslania
17. 25.843 340.409 ↑ 1.0 17,282 1

Hash Right Join (cost=26,879.47..31,091.74 rows=17,282 width=320) (actual time=294.762..340.409 rows=17,282 loops=1)

  • Hash Cond: (odoslanie.id = dv.odoslanie_id)
18. 19.976 19.976 ↑ 1.0 108,918 1

Seq Scan on d_odoslanie odoslanie (cost=0.00..3,617.18 rows=108,918 width=17) (actual time=0.045..19.976 rows=108,918 loops=1)

19. 10.289 294.590 ↑ 1.0 17,282 1

Hash (cost=26,663.45..26,663.45 rows=17,282 width=324) (actual time=294.590..294.590 rows=17,282 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 5313kB
20. 3.723 284.301 ↑ 1.0 17,282 1

Hash Left Join (cost=18,221.55..26,663.45 rows=17,282 width=324) (actual time=196.824..284.301 rows=17,282 loops=1)

  • Hash Cond: (workflowst7_.workflowprechod_id = workflowpr9_.id)
21. 4.447 280.208 ↑ 1.0 17,282 1

Hash Left Join (cost=18,171.13..26,567.66 rows=17,282 width=278) (actual time=196.445..280.208 rows=17,282 loops=1)

  • Hash Cond: (stav.faza_id = faza.id)
22. 4.800 275.686 ↑ 1.0 17,282 1

Hash Left Join (cost=18,160.97..26,511.30 rows=17,282 width=282) (actual time=196.365..275.686 rows=17,282 loops=1)

  • Hash Cond: (workflowst8_.stav_id = stav.id)
23. 4.840 270.780 ↑ 1.0 17,282 1

Hash Left Join (cost=18,147.13..26,451.46 rows=17,282 width=262) (actual time=196.253..270.780 rows=17,282 loops=1)

  • Hash Cond: (workflowst7_.workflowstav_id = workflowst8_.id)
24. 23.486 265.796 ↑ 1.0 17,282 1

Hash Right Join (cost=18,128.50..26,387.10 rows=17,282 width=256) (actual time=196.099..265.796 rows=17,282 loops=1)

  • Hash Cond: (dv.id = zonfpverzia.draftzonfp_id)
25. 46.355 46.355 ↑ 1.0 42,311 1

Seq Scan on d_zonfpdraftverzia dv (cost=0.00..7,927.11 rows=42,311 width=16) (actual time=0.020..46.355 rows=42,311 loops=1)

26. 8.085 195.955 ↑ 1.0 17,282 1

Hash (cost=17,912.48..17,912.48 rows=17,282 width=256) (actual time=195.955..195.955 rows=17,282 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 4962kB
27. 29.840 187.870 ↑ 1.0 17,282 1

Hash Right Join (cost=13,162.31..17,912.48 rows=17,282 width=256) (actual time=136.907..187.870 rows=17,282 loops=1)

  • Hash Cond: (workflowst7_.id = zonfp.workflowstavaktualny_id)
28. 21.270 21.270 ↑ 1.0 178,789 1

Seq Scan on d_workflowstavaktualny workflowst7_ (cost=0.00..3,906.89 rows=178,789 width=25) (actual time=0.019..21.270 rows=178,789 loops=1)

29. 9.058 136.760 ↑ 1.0 17,282 1

Hash (cost=12,946.28..12,946.28 rows=17,282 width=247) (actual time=136.760..136.760 rows=17,282 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 4820kB
30. 5.631 127.702 ↑ 1.0 17,282 1

Hash Left Join (cost=4,805.25..12,946.28 rows=17,282 width=247) (actual time=42.163..127.702 rows=17,282 loops=1)

  • Hash Cond: (projekt.aktualnaverzia_id = projektverzia.id)
31. 5.431 109.771 ↑ 1.0 17,282 1

Hash Left Join (cost=2,947.67..11,043.32 rows=17,282 width=188) (actual time=29.747..109.771 rows=17,282 loops=1)

  • Hash Cond: (zonfp.projekt_id = projekt.id)
32. 3.928 101.909 ↑ 1.0 17,282 1

Hash Join (cost=2,620.25..10,670.52 rows=17,282 width=180) (actual time=27.245..101.909 rows=17,282 loops=1)

  • Hash Cond: (vyzvaverzia.vyhlasovatel_id = oif.id)
33. 4.614 97.895 ↑ 1.0 17,282 1

Hash Join (cost=2,611.50..10,615.50 rows=17,282 width=151) (actual time=27.154..97.895 rows=17,282 loops=1)

  • Hash Cond: (zonfpverzia.vyzvaverzia_id = vyzvaverzia.id)
34. 8.035 91.839 ↑ 1.0 17,282 1

Hash Join (cost=2,365.89..10,324.42 rows=17,282 width=151) (actual time=25.702..91.839 rows=17,282 loops=1)

  • Hash Cond: (zonfpverzia.ziadatel_id = subjekt.id)
35. 15.331 66.066 ↑ 1.0 17,282 1

Hash Join (cost=726.85..8,447.75 rows=17,282 width=124) (actual time=7.884..66.066 rows=17,282 loops=1)

  • Hash Cond: (zonfpverzia.id = zonfp.verziazonfpaktualna_id)
36. 42.983 42.983 ↑ 1.0 38,915 1

Seq Scan on d_zonfpverzia zonfpverzia (cost=0.00..7,402.15 rows=38,915 width=116) (actual time=0.020..42.983 rows=38,915 loops=1)

37. 2.989 7.752 ↑ 1.0 17,282 1

Hash (cost=510.82..510.82 rows=17,282 width=40) (actual time=7.751..7.752 rows=17,282 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 1276kB
38. 4.763 4.763 ↑ 1.0 17,282 1

Seq Scan on d_zonfp zonfp (cost=0.00..510.82 rows=17,282 width=40) (actual time=0.016..4.763 rows=17,282 loops=1)

39. 2.650 17.738 ↑ 1.0 14,643 1

Hash (cost=1,456.01..1,456.01 rows=14,643 width=43) (actual time=17.738..17.738 rows=14,643 loops=1)

  • Buckets: 16384 Batches: 1 Memory Usage: 1194kB
40. 6.238 15.088 ↑ 1.0 14,643 1

Hash Join (cost=515.47..1,456.01 rows=14,643 width=43) (actual time=4.218..15.088 rows=14,643 loops=1)

  • Hash Cond: (subjektverzia.id = subjekt.subjektverziaaktualna_id)
41. 4.730 4.730 ↑ 1.0 24,517 1

Seq Scan on d_subjektverzia subjektverzia (cost=0.00..876.17 rows=24,517 width=43) (actual time=0.026..4.730 rows=24,517 loops=1)

42. 1.796 4.120 ↑ 1.0 14,643 1

Hash (cost=332.43..332.43 rows=14,643 width=16) (actual time=4.120..4.120 rows=14,643 loops=1)

  • Buckets: 16384 Batches: 1 Memory Usage: 815kB
43. 2.324 2.324 ↑ 1.0 14,643 1

Seq Scan on d_subjekt subjekt (cost=0.00..332.43 rows=14,643 width=16) (actual time=0.013..2.324 rows=14,643 loops=1)

44. 0.214 1.442 ↑ 1.0 1,894 1

Hash (cost=221.94..221.94 rows=1,894 width=16) (actual time=1.442..1.442 rows=1,894 loops=1)

  • Buckets: 2048 Batches: 1 Memory Usage: 105kB
45. 1.228 1.228 ↑ 1.0 1,894 1

Seq Scan on d_vyzvaverzia vyzvaverzia (cost=0.00..221.94 rows=1,894 width=16) (actual time=0.013..1.228 rows=1,894 loops=1)

46. 0.032 0.086 ↑ 1.0 211 1

Hash (cost=6.11..6.11 rows=211 width=45) (actual time=0.086..0.086 rows=211 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 25kB
47. 0.054 0.054 ↑ 1.0 211 1

Seq Scan on d_organimplementaciefondov oif (cost=0.00..6.11 rows=211 width=45) (actual time=0.021..0.054 rows=211 loops=1)

48. 0.983 2.431 ↑ 1.0 8,552 1

Hash (cost=220.52..220.52 rows=8,552 width=16) (actual time=2.431..2.431 rows=8,552 loops=1)

  • Buckets: 16384 Batches: 1 Memory Usage: 529kB
49. 1.448 1.448 ↑ 1.0 8,552 1

Seq Scan on d_projekt projekt (cost=0.00..220.52 rows=8,552 width=16) (actual time=0.017..1.448 rows=8,552 loops=1)

50. 1.888 12.300 ↑ 1.0 8,559 1

Hash (cost=1,750.59..1,750.59 rows=8,559 width=75) (actual time=12.300..12.300 rows=8,559 loops=1)

  • Buckets: 16384 Batches: 1 Memory Usage: 1057kB
51. 10.412 10.412 ↑ 1.0 8,559 1

Seq Scan on d_projektverzia projektverzia (cost=0.00..1,750.59 rows=8,559 width=75) (actual time=0.019..10.412 rows=8,559 loops=1)

52. 0.061 0.144 ↑ 1.0 517 1

Hash (cost=12.17..12.17 rows=517 width=22) (actual time=0.144..0.144 rows=517 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 37kB
53. 0.083 0.083 ↑ 1.0 517 1

Seq Scan on d_workflowstav workflowst8_ (cost=0.00..12.17 rows=517 width=22) (actual time=0.007..0.083 rows=517 loops=1)

54. 0.044 0.106 ↑ 1.0 304 1

Hash (cost=10.04..10.04 rows=304 width=36) (actual time=0.106..0.106 rows=304 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 30kB
55. 0.062 0.062 ↑ 1.0 304 1

Seq Scan on d_stav stav (cost=0.00..10.04 rows=304 width=36) (actual time=0.013..0.062 rows=304 loops=1)

56. 0.027 0.075 ↑ 1.0 229 1

Hash (cost=7.29..7.29 rows=229 width=12) (actual time=0.075..0.075 rows=229 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 19kB
57. 0.048 0.048 ↑ 1.0 229 1

Seq Scan on d_faza faza (cost=0.00..7.29 rows=229 width=12) (actual time=0.006..0.048 rows=229 loops=1)

58. 0.166 0.370 ↑ 1.0 1,219 1

Hash (cost=35.19..35.19 rows=1,219 width=62) (actual time=0.370..0.370 rows=1,219 loops=1)

  • Buckets: 2048 Batches: 1 Memory Usage: 133kB
59. 0.204 0.204 ↑ 1.0 1,219 1

Seq Scan on d_workflowprechod workflowpr9_ (cost=0.00..35.19 rows=1,219 width=62) (actual time=0.012..0.204 rows=1,219 loops=1)

60. 4.959 8.576 ↑ 1.0 38,915 1

Hash (cost=703.91..703.91 rows=38,915 width=8) (actual time=8.576..8.576 rows=38,915 loops=1)

  • Buckets: 65536 Batches: 1 Memory Usage: 2033kB
61. 3.617 3.617 ↑ 1.0 38,915 1

Index Only Scan using d_zonfpverzia_pkey on d_zonfpverzia zonfpverzi1_ (cost=0.29..703.91 rows=38,915 width=8) (actual time=0.014..3.617 rows=38,915 loops=1)

  • Heap Fetches: 0
62. 0.041 0.183 ↑ 1.0 261 1

Hash (cost=6.26..6.26 rows=261 width=8) (actual time=0.183..0.183 rows=261 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 19kB
63. 0.142 0.142 ↑ 1.0 261 1

Index Only Scan using d_specifickyciel_pkey on d_specifickyciel specificky3_ (cost=0.15..6.26 rows=261 width=8) (actual time=0.119..0.142 rows=261 loops=1)

  • Heap Fetches: 0
64. 5,006.974 15,020.922 ↑ 1.0 2 2,503,487

Bitmap Heap Scan on d_dokument dokument9_ (cost=3,904.52..3,906.75 rows=2 width=45) (actual time=0.005..0.006 rows=2 loops=2,503,487)

  • Recheck Cond: ((dokumenty8_.dokument_id = id) OR (dokumenty5_.dokument_id = id))
  • Heap Blocks: exact=4664406
65. 0.000 10,013.948 ↓ 0.0 0 2,503,487

BitmapOr (cost=3,904.52..3,904.52 rows=2 width=0) (actual time=0.004..0.004 rows=0 loops=2,503,487)

66. 5,006.974 5,006.974 ↑ 1.0 1 2,503,487

Bitmap Index Scan on d_dokument_pkey (cost=0.00..0.45 rows=1 width=0) (actual time=0.002..0.002 rows=1 loops=2,503,487)

  • Index Cond: (dokumenty8_.dokument_id = id)
67. 5,006.974 5,006.974 ↑ 1.0 1 2,503,487

Bitmap Index Scan on d_dokument_pkey (cost=0.00..0.68 rows=1 width=0) (actual time=0.002..0.002 rows=1 loops=2,503,487)

  • Index Cond: (dokumenty5_.dokument_id = id)
Planning time : 10.890 ms
Execution time : 74,874.271 ms