{"id":3525,"date":"2022-10-03T07:00:00","date_gmt":"2022-10-03T04:00:00","guid":{"rendered":"https:\/\/www.dataplatform.gr\/?p=3525"},"modified":"2023-11-05T21:37:49","modified_gmt":"2023-11-05T18:37:49","slug":"giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k","status":"publish","type":"post","link":"https:\/\/www.dataplatform.gr\/en\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/","title":{"rendered":"Why can&#039;t I shrink the transaction log in SQL Server and why is it full?"},"content":{"rendered":"<p>In <a href=\"https:\/\/www.dataplatform.gr\/en\/ti-einai-to-transaction-log-kai-poy-chrisimeyei-ston-sql\/\" target=\"_blank\" rel=\"noreferrer noopener\">previous<\/a> article we had seen what the Transaction Log is. This time we&#039;ll see how we can empty it and make it shrink, we&#039;ll also see what we can do case by case when it won&#039;t let us.<\/p>\n\n\n\n<p>Suddenly one day we see that the transactions in a certain database in SQL Server are not running and that the disk where the Transaction Log files are stored is full. What are we doing;<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How do we shrink the transaction log?<\/h2>\n\n\n\n<p>For starters, with the following function we will see the size of the transaction log of each base and its percentage of use:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">dbcc sqlperf(logspace);<\/pre>\n\n\n\n<p>After running it, we see that on a specific basis it has reached 40GB and uses its 100%:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"418\" height=\"257\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-01.png\" alt=\"\" class=\"wp-image-3526\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-01.png 418w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-01-300x184.png 300w\" sizes=\"auto, (max-width: 418px) 100vw, 418px\" \/><figcaption class=\"wp-element-caption\">01<\/figcaption><\/figure>\n\n\n\n<p>To see the name of the transaction log file that has been filled, run the following in the database:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">select name,(size*8\/1024\/1024) SizeGB from sys.database_Files where type_desc = 'LOG';<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"242\" height=\"117\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-13.png\" alt=\"\" class=\"wp-image-3551\"\/><figcaption class=\"wp-element-caption\">02<\/figcaption><\/figure>\n\n\n\n<p>Now that we have the name with the function <em>DBCC SHRINKFILE<\/em> we can try shrinking the file down to 1024mb:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">USE [StackOverflow2013]\nGO\nDBCC SHRINKFILE ('StackOverflow2013_log5' , 1024);<\/pre>\n\n\n\n<p>However, it shows us the following message that tells us that the space is needed, so we have not done something right:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"673\" height=\"153\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-02.png\" alt=\"\" class=\"wp-image-3527\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-02.png 673w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-02-300x68.png 300w\" sizes=\"auto, (max-width: 673px) 100vw, 673px\" \/><figcaption class=\"wp-element-caption\">03<\/figcaption><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Why doesn&#039;t it let us shrink the transaction log?<\/h2>\n\n\n\n<p>Let&#039;s see how much space they take up <strong><em>Virtual Log Files<\/em><\/strong> where is <strong>in Active status <\/strong>which cannot be deleted:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">select sum(vlf_size_mb) ActiveVLFsizeMB from sys.dm_db_log_info(DB_ID('StackOverflow2013'))\nwhere 1=1\nand vlf_status = 2;\n\n--\u0391\u03bd \u03b7 \u03ad\u03ba\u03b4\u03bf\u03c3\u03b7 \u03b5\u03af\u03bd\u03b1\u03b9 \u03c0\u03c1\u03b9\u03bd \u03c4\u03b7\u03bd 2016 \u03c4\u03cc\u03c4\u03b5 \u03b4\u03b5\u03bd \u03b4\u03bf\u03c5\u03bb\u03b5\u03cd\u03b5\u03b9 \u03c4\u03bf view \u03ba\u03b1\u03b9 \u03c4\u03c1\u03ad\u03c7\u03bf\u03c5\u03bc\u03b5 \u03c4\u03b7\u03bd loginfo:\ndbcc loginfo;\n<\/pre>\n\n\n\n<p>We see that it takes several gigabytes. This means that <strong>whether there is a transaction in progress<\/strong> either \/ and must <strong>to backup the transaction log<\/strong> in case our base is in <strong>Full recovery model.<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"229\" height=\"91\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-03.png\" alt=\"\" class=\"wp-image-3528\"\/><figcaption class=\"wp-element-caption\">04<\/figcaption><\/figure>\n\n\n\n<p>Let&#039;s see what <strong>Recovery Model<\/strong> is our base:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">select name,recovery_model_desc from sys.databases;<\/pre>\n\n\n\n<p>We see that it is in <strong>Full<\/strong>, which means that in order to reduce the percentage and let us shrink the transaction log we should first take a transaction log backup:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"308\" height=\"284\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-12.png\" alt=\"\" class=\"wp-image-3549\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-12.png 308w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-12-300x277.png 300w\" sizes=\"auto, (max-width: 308px) 100vw, 308px\" \/><figcaption class=\"wp-element-caption\">05<\/figcaption><\/figure>\n\n\n\n<p>Let&#039;s try to run a job that will take a transaction log backup:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">exec msdb.dbo.sp_start_job 'DatabaseBackup - USER_DATABASES - LOG';<\/pre>\n\n\n\n<p>After the backup is finished, wait a bit and try again to see the log:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">dbcc sqlperf(logspace);<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"418\" height=\"257\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-01.png\" alt=\"\" class=\"wp-image-3526\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-01.png 418w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-01-300x184.png 300w\" sizes=\"auto, (max-width: 418px) 100vw, 418px\" \/><figcaption class=\"wp-element-caption\">06<\/figcaption><\/figure>\n\n\n\n<p>We see again that it is 100%, so even though nothing is running in the base, some transaction must have been left open. We can search for this with the function <em>DBCC OPENTRAN<\/em>:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">dbcc opentran;<\/pre>\n\n\n\n<p>We see that there is an open transaction on session id 68\u2026:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"674\" height=\"221\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-04.png\" alt=\"\" class=\"wp-image-3529\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-04.png 674w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-04-300x98.png 300w\" sizes=\"auto, (max-width: 674px) 100vw, 674px\" \/><figcaption class=\"wp-element-caption\">07<\/figcaption><\/figure>\n\n\n\n<p>Checking with the following what is currently running in the database with session_id 68 finds no result:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">select * from sys.dm_exec_requests where session_id=68;<\/pre>\n\n\n\n<p>But somewhere here I had mocked you, as from the beginning I had left a transaction which, although the delete had completed, <strong>I had not closed it with commit or rollback<\/strong> and remained active in the transaction log:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"301\" height=\"146\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-05.png\" alt=\"\" class=\"wp-image-3530\"\/><figcaption class=\"wp-element-caption\">08<\/figcaption><\/figure>\n\n\n\n<p>We can now do <em>kill<\/em> the session id 68 and to see the status of the rollback with the following: <\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">kill 68\nkill 68 with statusonly<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"856\" height=\"95\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-06.png\" alt=\"\" class=\"wp-image-3531\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-06.png 856w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-06-300x33.png 300w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-06-768x85.png 768w\" sizes=\"auto, (max-width: 856px) 100vw, 856px\" \/><figcaption class=\"wp-element-caption\">09<\/figcaption><\/figure>\n\n\n\n<p>Now we need to back up the transaction log again:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">exec msdb.dbo.sp_start_job 'DatabaseBackup - USER_DATABASES - LOG';<\/pre>\n\n\n\n<p>So now if we look again at the active Virtual Log Files we will see that the size has dropped:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">select sum(vlf_size_mb) ActiveVLFsizeMB from sys.dm_db_log_info(DB_ID('StackOverflow2013'))\nwhere 1=1\nand vlf_status = 2;\n\n--\u0391\u03bd \u03b7 \u03ad\u03ba\u03b4\u03bf\u03c3\u03b7 \u03b5\u03af\u03bd\u03b1\u03b9 \u03c0\u03c1\u03b9\u03bd \u03c4\u03b7\u03bd 2016 \u03c4\u03cc\u03c4\u03b5 \u03b4\u03b5\u03bd \u03b4\u03bf\u03c5\u03bb\u03b5\u03cd\u03b5\u03b9 \u03c4\u03bf view \u03ba\u03b1\u03b9 \u03c4\u03c1\u03ad\u03c7\u03bf\u03c5\u03bc\u03b5 \u03c4\u03b7\u03bd loginfo:\ndbcc loginfo;<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"181\" height=\"117\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-08.png\" alt=\"\" class=\"wp-image-3534\"\/><figcaption class=\"wp-element-caption\">10<\/figcaption><\/figure>\n\n\n\n<p>And we check the transaction log rate again:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">dbcc sqlperf(logspace);<\/pre>\n\n\n\n<p>We will see that it is now used under 1% of the transaction log:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"421\" height=\"271\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-11.png\" alt=\"\" class=\"wp-image-3545\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-11.png 421w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-11-300x193.png 300w\" sizes=\"auto, (max-width: 421px) 100vw, 421px\" \/><figcaption class=\"wp-element-caption\">11<\/figcaption><\/figure>\n\n\n\n<p>So now we will be able to do <em>shrink<\/em>:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">USE [StackOverflow2013]\nGO\nDBCC SHRINKFILE ('StackOverflow2013_log5' , 1024);<\/pre>\n\n\n\n<p>We see that it completed successfully this time:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"670\" height=\"79\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-14.png\" alt=\"\" class=\"wp-image-3587\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-14.png 670w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-14-300x35.png 300w\" sizes=\"auto, (max-width: 670px) 100vw, 670px\" \/><\/figure>\n\n\n\n<p>If we look again at the space in the transaction log:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">dbcc sqlperf(logspace);<\/pre>\n\n\n\n<p>We will see that it dropped from the physical size of 50GB to the 1GB we set for it:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"468\" height=\"257\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-09.png\" alt=\"\" class=\"wp-image-3533\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-09.png 468w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-09-300x165.png 300w\" sizes=\"auto, (max-width: 468px) 100vw, 468px\" \/><figcaption class=\"wp-element-caption\">12<\/figcaption><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">If any previous VLF remains active<\/h2>\n\n\n\n<p>If the following message appears, it means that a Virtual Log File that precedes the next ones that have been emptied is still active (we can see it with<em> dbcc loginfo<\/em> looking for those with status 2). <\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"885\" height=\"161\" src=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-10.png\" alt=\"\" class=\"wp-image-3536\" srcset=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-10.png 885w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-10-300x55.png 300w, https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2021\/06\/lgsq-10-768x140.png 768w\" sizes=\"auto, (max-width: 885px) 100vw, 885px\" \/><figcaption class=\"wp-element-caption\">13<\/figcaption><\/figure>\n\n\n\n<p>Then we try to take a transaction log backup again and then shrink again.<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>If it still shows us this message, even though we have let it pass and some time may be responsible for an Availability Group, transactional replication or something else.<\/p>\n\n\n\n<p>So as an emergency solution we can temporarily lose the Point in Time feature for after the last transaction log backup but fix the problem by running the following:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"sql\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\" data-no-translation=\"\" data-no-auto-translation=\"\">USE [StackOverflow2013] \nGO  \nALTER DATABASE [StackOverflow2013]\nSET RECOVERY SIMPLE;  \nGO  \n\nCHECKPOINT;\nDBCC SHRINKFILE ('StackOverflow2013_log5', 1);  \nGO  \n\nALTER DATABASE [StackOverflow2013]\nSET RECOVERY FULL;  \nGO <\/pre>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Sources:<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/sql\/relational-databases\/logs\/the-transaction-log-sql-server?view=sql-server-ver15\" target=\"_blank\" rel=\"noreferrer noopener\">The Transaction Log (SQL Server)<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/sql\/relational-databases\/databases\/shrink-a-file?view=sql-server-ver15\" target=\"_blank\" rel=\"noreferrer noopener\">Shrink a File<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/sql\/t-sql\/database-console-commands\/dbcc-opentran-transact-sql?view=sql-server-ver15\">DBCC OPENTRAN (Transact-SQL)<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/sql\/t-sql\/database-console-commands\/dbcc-sqlperf-transact-sql?view=sql-server-ver15\" target=\"_blank\" rel=\"noreferrer noopener\">DBCC SQLPERF (Transact-SQL)<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/sql\/t-sql\/database-console-commands\/dbcc-shrinkfile-transact-sql?redirectedfrom=MSDN&amp;view=sql-server-ver15\" target=\"_blank\" rel=\"noreferrer noopener\">DBCC SHRINKFILE (Transact-SQL)<\/a><\/li>\n<\/ul>\n\n\n\n<p><\/p>","protected":false},"excerpt":{"rendered":"<p>In a previous article we saw what the Transaction Log is. This time we&#039;ll see how we can empty it and make it shrink, we&#039;ll also see what we can do case by case when it won&#039;t let us. Suddenly, one day we see that the transactions in a certain database in SQL Server do not stop us [...]<\/p>","protected":false},"author":1,"featured_media":702,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11,15],"tags":[23,30,6],"class_list":["post-3525","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-databases","category-ms-sqlserver","tag-microsoft","tag-rdbms","tag-sqlserver"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5 - DataPlatform.gr<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.dataplatform.gr\/en\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5 - DataPlatform.gr\" \/>\n<meta property=\"og:description\" content=\"\u03a3\u03b5 \u03c0\u03c1\u03bf\u03b7\u03b3\u03bf\u03cd\u03bc\u03b5\u03bd\u03bf \u03ac\u03c1\u03b8\u03c1\u03bf \u03b5\u03af\u03c7\u03b1\u03bc\u03b5 \u03b4\u03b5\u03b9 \u03c4\u03b9 \u03b5\u03af\u03bd\u03b1\u03b9 \u03c4\u03bf Transaction Log. \u0391\u03c5\u03c4\u03ae \u03c4\u03b7 \u03c6\u03bf\u03c1\u03ac \u03b8\u03b1 \u03b4\u03bf\u03cd\u03bc\u03b5 \u03c0\u03c9\u03c2 \u03bc\u03c0\u03bf\u03c1\u03bf\u03cd\u03bc\u03b5 \u03bd\u03b1 \u03c4\u03bf \u03b1\u03b4\u03b5\u03af\u03b1\u03c3\u03bf\u03c5\u03bc\u03b5 \u03ba\u03b1\u03b9 \u03bd\u03b1 \u03c4\u03bf \u03ba\u03ac\u03bd\u03bf\u03c5\u03bc\u03b5 shrink, \u03b5\u03c0\u03af\u03c3\u03b7\u03c2 \u03b8\u03b1 \u03b4\u03bf\u03cd\u03bc\u03b5 \u03c4\u03b9 \u03bc\u03c0\u03bf\u03c1\u03bf\u03cd\u03bc\u03b5 \u03bd\u03b1 \u03ba\u03ac\u03bd\u03bf\u03c5\u03bc\u03b5 \u03b1\u03bd\u03ac \u03c0\u03b5\u03c1\u03af\u03c0\u03c4\u03c9\u03c3\u03b7 \u03cc\u03c4\u03b1\u03bd \u03b4\u03b5\u03bd \u03bc\u03b1\u03c2 \u03b1\u03c6\u03ae\u03bd\u03b5\u03b9. \u039e\u03b1\u03c6\u03bd\u03b9\u03ba\u03ac \u03bc\u03b9\u03b1 \u03bc\u03ad\u03c1\u03b1 \u03b2\u03bb\u03ad\u03c0\u03bf\u03c5\u03bc\u03b5 \u03bd\u03b1 \u03bc\u03b7\u03bd \u03bc\u03b1\u03c2 \u03c3\u03ba\u03ac\u03bd\u03b5 \u03bf\u03b9 \u03c3\u03c5\u03bd\u03b1\u03bb\u03bb\u03b1\u03b3\u03ad\u03c2 \u03c3\u03b5 \u03c3\u03c5\u03b3\u03ba\u03b5\u03ba\u03c1\u03b9\u03bc\u03ad\u03bd\u03b7 \u03b2\u03ac\u03c3\u03b7 \u03b4\u03b5\u03b4\u03bf\u03bc\u03ad\u03bd\u03c9\u03bd \u03c3\u03c4\u03bf\u03bd SQL Server [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.dataplatform.gr\/en\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/\" \/>\n<meta property=\"og:site_name\" content=\"DataPlatform.gr\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/dataplatform.gr\/\" \/>\n<meta property=\"article:published_time\" content=\"2022-10-03T04:00:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-11-05T18:37:49+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2020\/06\/dp_sqlserver.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1280\" \/>\n\t<meta property=\"og:image:height\" content=\"720\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Stratos Matzouranis\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Stratos Matzouranis\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"7 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/\"},\"author\":{\"name\":\"Stratos Matzouranis\",\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/#\\\/schema\\\/person\\\/e87bf4fd02b65cb6aa0942f87245bbaf\"},\"headline\":\"\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5\",\"datePublished\":\"2022-10-03T04:00:00+00:00\",\"dateModified\":\"2023-11-05T18:37:49+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/\"},\"wordCount\":132,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.dataplatform.gr\\\/wp-content\\\/uploads\\\/2020\\\/06\\\/dp_sqlserver.png\",\"keywords\":[\"Microsoft\",\"RDBMS\",\"SQL Server\"],\"articleSection\":[\"Databases\",\"Microsoft SQL Server\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/\",\"url\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/\",\"name\":\"\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5 - DataPlatform.gr\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.dataplatform.gr\\\/wp-content\\\/uploads\\\/2020\\\/06\\\/dp_sqlserver.png\",\"datePublished\":\"2022-10-03T04:00:00+00:00\",\"dateModified\":\"2023-11-05T18:37:49+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.dataplatform.gr\\\/wp-content\\\/uploads\\\/2020\\\/06\\\/dp_sqlserver.png\",\"contentUrl\":\"https:\\\/\\\/www.dataplatform.gr\\\/wp-content\\\/uploads\\\/2020\\\/06\\\/dp_sqlserver.png\",\"width\":1280,\"height\":720},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u0391\u03c1\u03c7\u03b9\u03ba\u03ae\",\"item\":\"https:\\\/\\\/www.dataplatform.gr\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Databases\",\"item\":\"https:\\\/\\\/www.dataplatform.gr\\\/category\\\/databases\\\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Microsoft SQL Server\",\"item\":\"https:\\\/\\\/www.dataplatform.gr\\\/category\\\/databases\\\/ms-sqlserver\\\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/#website\",\"url\":\"https:\\\/\\\/www.dataplatform.gr\\\/\",\"name\":\"dataplatform.gr - Sky is not the limit!\",\"description\":\"\u0398\u03b5\u03c9\u03c1\u03af\u03b1, \u03bf\u03b4\u03b7\u03b3\u03bf\u03af \u03ba\u03b1\u03b9 \u03c3\u03ba\u03ad\u03c8\u03b5\u03b9\u03c2 \u03b3\u03b9\u03b1 \u03bd\u03b1 \u03ba\u03ac\u03bd\u03b5\u03c4\u03b5 \u03c4\u03b7 \u03b4\u03bf\u03c5\u03bb\u03b5\u03b9\u03ac \u03c3\u03b1\u03c2 \u03c0\u03b9\u03bf \u03c0\u03b1\u03c1\u03b1\u03b3\u03c9\u03b3\u03b9\u03ba\u03ac \u03ba\u03b1\u03b9 \u03c0\u03b9\u03bf \u03b5\u03cd\u03ba\u03bf\u03bb\u03b1 \u03c0\u03ac\u03bd\u03c9 \u03c3\u03c4\u03b9\u03c2 \u03b2\u03ac\u03c3\u03b5\u03b9\u03c2 \u03b4\u03b5\u03b4\u03bf\u03bc\u03ad\u03bd\u03c9\u03bd, \u03c3\u03c4\u03b7\u03bd SQL, \u03c3\u03c4\u03bf Business Intelligence \u03ba\u03b1\u03b9 \u03c3\u03c4\u03b1 \u03b4\u03b5\u03b4\u03bf\u03bc\u03ad\u03bd\u03b1 \u03b3\u03b5\u03bd\u03b9\u03ba\u03cc\u03c4\u03b5\u03c1\u03b1.\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.dataplatform.gr\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/#organization\",\"name\":\"dataplatform.gr\",\"url\":\"https:\\\/\\\/www.dataplatform.gr\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.dataplatform.gr\\\/wp-content\\\/uploads\\\/2020\\\/06\\\/dp_logo_wbacki.png\",\"contentUrl\":\"https:\\\/\\\/www.dataplatform.gr\\\/wp-content\\\/uploads\\\/2020\\\/06\\\/dp_logo_wbacki.png\",\"width\":322,\"height\":139,\"caption\":\"dataplatform.gr\"},\"image\":{\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/dataplatform.gr\\\/\",\"https:\\\/\\\/www.linkedin.com\\\/company\\\/dataplatform-gr\\\/\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.dataplatform.gr\\\/#\\\/schema\\\/person\\\/e87bf4fd02b65cb6aa0942f87245bbaf\",\"name\":\"Stratos Matzouranis\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/ab973bc4bd1673c43d45de5633a624d9ad13c06902dfdd5a6e3fd9885903865e?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/ab973bc4bd1673c43d45de5633a624d9ad13c06902dfdd5a6e3fd9885903865e?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/ab973bc4bd1673c43d45de5633a624d9ad13c06902dfdd5a6e3fd9885903865e?s=96&d=mm&r=g\",\"caption\":\"Stratos Matzouranis\"},\"sameAs\":[\"https:\\\/\\\/www.dataplatform.gr\"],\"url\":\"https:\\\/\\\/www.dataplatform.gr\\\/en\\\/author\\\/stratos-matzouranis\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5 - DataPlatform.gr","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.dataplatform.gr\/en\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/","og_locale":"en_US","og_type":"article","og_title":"\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5 - DataPlatform.gr","og_description":"\u03a3\u03b5 \u03c0\u03c1\u03bf\u03b7\u03b3\u03bf\u03cd\u03bc\u03b5\u03bd\u03bf \u03ac\u03c1\u03b8\u03c1\u03bf \u03b5\u03af\u03c7\u03b1\u03bc\u03b5 \u03b4\u03b5\u03b9 \u03c4\u03b9 \u03b5\u03af\u03bd\u03b1\u03b9 \u03c4\u03bf Transaction Log. \u0391\u03c5\u03c4\u03ae \u03c4\u03b7 \u03c6\u03bf\u03c1\u03ac \u03b8\u03b1 \u03b4\u03bf\u03cd\u03bc\u03b5 \u03c0\u03c9\u03c2 \u03bc\u03c0\u03bf\u03c1\u03bf\u03cd\u03bc\u03b5 \u03bd\u03b1 \u03c4\u03bf \u03b1\u03b4\u03b5\u03af\u03b1\u03c3\u03bf\u03c5\u03bc\u03b5 \u03ba\u03b1\u03b9 \u03bd\u03b1 \u03c4\u03bf \u03ba\u03ac\u03bd\u03bf\u03c5\u03bc\u03b5 shrink, \u03b5\u03c0\u03af\u03c3\u03b7\u03c2 \u03b8\u03b1 \u03b4\u03bf\u03cd\u03bc\u03b5 \u03c4\u03b9 \u03bc\u03c0\u03bf\u03c1\u03bf\u03cd\u03bc\u03b5 \u03bd\u03b1 \u03ba\u03ac\u03bd\u03bf\u03c5\u03bc\u03b5 \u03b1\u03bd\u03ac \u03c0\u03b5\u03c1\u03af\u03c0\u03c4\u03c9\u03c3\u03b7 \u03cc\u03c4\u03b1\u03bd \u03b4\u03b5\u03bd \u03bc\u03b1\u03c2 \u03b1\u03c6\u03ae\u03bd\u03b5\u03b9. \u039e\u03b1\u03c6\u03bd\u03b9\u03ba\u03ac \u03bc\u03b9\u03b1 \u03bc\u03ad\u03c1\u03b1 \u03b2\u03bb\u03ad\u03c0\u03bf\u03c5\u03bc\u03b5 \u03bd\u03b1 \u03bc\u03b7\u03bd \u03bc\u03b1\u03c2 \u03c3\u03ba\u03ac\u03bd\u03b5 \u03bf\u03b9 \u03c3\u03c5\u03bd\u03b1\u03bb\u03bb\u03b1\u03b3\u03ad\u03c2 \u03c3\u03b5 \u03c3\u03c5\u03b3\u03ba\u03b5\u03ba\u03c1\u03b9\u03bc\u03ad\u03bd\u03b7 \u03b2\u03ac\u03c3\u03b7 \u03b4\u03b5\u03b4\u03bf\u03bc\u03ad\u03bd\u03c9\u03bd \u03c3\u03c4\u03bf\u03bd SQL Server [&hellip;]","og_url":"https:\/\/www.dataplatform.gr\/en\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/","og_site_name":"DataPlatform.gr","article_publisher":"https:\/\/www.facebook.com\/dataplatform.gr\/","article_published_time":"2022-10-03T04:00:00+00:00","article_modified_time":"2023-11-05T18:37:49+00:00","og_image":[{"width":1280,"height":720,"url":"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2020\/06\/dp_sqlserver.png","type":"image\/png"}],"author":"Stratos Matzouranis","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Stratos Matzouranis","Est. reading time":"7 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/#article","isPartOf":{"@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/"},"author":{"name":"Stratos Matzouranis","@id":"https:\/\/www.dataplatform.gr\/#\/schema\/person\/e87bf4fd02b65cb6aa0942f87245bbaf"},"headline":"\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5","datePublished":"2022-10-03T04:00:00+00:00","dateModified":"2023-11-05T18:37:49+00:00","mainEntityOfPage":{"@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/"},"wordCount":132,"commentCount":0,"publisher":{"@id":"https:\/\/www.dataplatform.gr\/#organization"},"image":{"@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2020\/06\/dp_sqlserver.png","keywords":["Microsoft","RDBMS","SQL Server"],"articleSection":["Databases","Microsoft SQL Server"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/","url":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/","name":"\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5 - DataPlatform.gr","isPartOf":{"@id":"https:\/\/www.dataplatform.gr\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/#primaryimage"},"image":{"@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2020\/06\/dp_sqlserver.png","datePublished":"2022-10-03T04:00:00+00:00","dateModified":"2023-11-05T18:37:49+00:00","breadcrumb":{"@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/#primaryimage","url":"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2020\/06\/dp_sqlserver.png","contentUrl":"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2020\/06\/dp_sqlserver.png","width":1280,"height":720},{"@type":"BreadcrumbList","@id":"https:\/\/www.dataplatform.gr\/giati-den-mporo-na-kano-shrink-to-transaction-log-ston-sql-server-k\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u0391\u03c1\u03c7\u03b9\u03ba\u03ae","item":"https:\/\/www.dataplatform.gr\/"},{"@type":"ListItem","position":2,"name":"Databases","item":"https:\/\/www.dataplatform.gr\/category\/databases\/"},{"@type":"ListItem","position":3,"name":"Microsoft SQL Server","item":"https:\/\/www.dataplatform.gr\/category\/databases\/ms-sqlserver\/"},{"@type":"ListItem","position":4,"name":"\u0393\u03b9\u03b1\u03c4\u03af \u03b4\u03b5\u03bd \u03bc\u03c0\u03bf\u03c1\u03ce \u03bd\u03b1 \u03ba\u03ac\u03bd\u03c9 shrink \u03c4\u03bf transaction log \u03c3\u03c4\u03bf\u03bd SQL Server \u03ba\u03b1\u03b9 \u03b3\u03b9\u03b1\u03c4\u03af \u03b3\u03ad\u03bc\u03b9\u03c3\u03b5"}]},{"@type":"WebSite","@id":"https:\/\/www.dataplatform.gr\/#website","url":"https:\/\/www.dataplatform.gr\/","name":"dataplatform.gr - Sky is not the limit!","description":"\u0398\u03b5\u03c9\u03c1\u03af\u03b1, \u03bf\u03b4\u03b7\u03b3\u03bf\u03af \u03ba\u03b1\u03b9 \u03c3\u03ba\u03ad\u03c8\u03b5\u03b9\u03c2 \u03b3\u03b9\u03b1 \u03bd\u03b1 \u03ba\u03ac\u03bd\u03b5\u03c4\u03b5 \u03c4\u03b7 \u03b4\u03bf\u03c5\u03bb\u03b5\u03b9\u03ac \u03c3\u03b1\u03c2 \u03c0\u03b9\u03bf \u03c0\u03b1\u03c1\u03b1\u03b3\u03c9\u03b3\u03b9\u03ba\u03ac \u03ba\u03b1\u03b9 \u03c0\u03b9\u03bf \u03b5\u03cd\u03ba\u03bf\u03bb\u03b1 \u03c0\u03ac\u03bd\u03c9 \u03c3\u03c4\u03b9\u03c2 \u03b2\u03ac\u03c3\u03b5\u03b9\u03c2 \u03b4\u03b5\u03b4\u03bf\u03bc\u03ad\u03bd\u03c9\u03bd, \u03c3\u03c4\u03b7\u03bd SQL, \u03c3\u03c4\u03bf Business Intelligence \u03ba\u03b1\u03b9 \u03c3\u03c4\u03b1 \u03b4\u03b5\u03b4\u03bf\u03bc\u03ad\u03bd\u03b1 \u03b3\u03b5\u03bd\u03b9\u03ba\u03cc\u03c4\u03b5\u03c1\u03b1.","publisher":{"@id":"https:\/\/www.dataplatform.gr\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.dataplatform.gr\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.dataplatform.gr\/#organization","name":"dataplatform.gr","url":"https:\/\/www.dataplatform.gr\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.dataplatform.gr\/#\/schema\/logo\/image\/","url":"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2020\/06\/dp_logo_wbacki.png","contentUrl":"https:\/\/www.dataplatform.gr\/wp-content\/uploads\/2020\/06\/dp_logo_wbacki.png","width":322,"height":139,"caption":"dataplatform.gr"},"image":{"@id":"https:\/\/www.dataplatform.gr\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/dataplatform.gr\/","https:\/\/www.linkedin.com\/company\/dataplatform-gr\/"]},{"@type":"Person","@id":"https:\/\/www.dataplatform.gr\/#\/schema\/person\/e87bf4fd02b65cb6aa0942f87245bbaf","name":"Stratos Matzouranis","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/ab973bc4bd1673c43d45de5633a624d9ad13c06902dfdd5a6e3fd9885903865e?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/ab973bc4bd1673c43d45de5633a624d9ad13c06902dfdd5a6e3fd9885903865e?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/ab973bc4bd1673c43d45de5633a624d9ad13c06902dfdd5a6e3fd9885903865e?s=96&d=mm&r=g","caption":"Stratos Matzouranis"},"sameAs":["https:\/\/www.dataplatform.gr"],"url":"https:\/\/www.dataplatform.gr\/en\/author\/stratos-matzouranis\/"}]}},"_links":{"self":[{"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/posts\/3525","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/comments?post=3525"}],"version-history":[{"count":1,"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/posts\/3525\/revisions"}],"predecessor-version":[{"id":5616,"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/posts\/3525\/revisions\/5616"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/media\/702"}],"wp:attachment":[{"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/media?parent=3525"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/categories?post=3525"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dataplatform.gr\/en\/wp-json\/wp\/v2\/tags?post=3525"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}