Please start any new threads on our new site at We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
Save Password
Forgot your Password?

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 unable to shrink mdf file
 Reply to Topic
 Printer Friendly
Previous Page
Author Previous Topic Topic Next Topic
Page: of 2

Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)

7020 Posts

Posted - 06/27/2013 :  10:29:23  Show Profile  Reply with Quote
Originally posted by ditch

Nope I haven't. But what is working is your approach where you shrink by blocks of 100MB.
That seems to be working great.

My concern with rebuilding indexes is the amount of time that it will interfere with production as some of our tables are quite large (in excess of 3 Billion rows).


You may want to just go with reorganize instead of rebuild on those large tables.

If you do a rebuild, you will need as much free space in that database as the clustered index of the largest table, and that might defeat the purpose of doing a shrink.

Also, unless you can do an online rebuild, those large tables may be locked for an extended amount of time. A reorganize is an online operation, so the tables would remain available.


Edited by - Michael Valentine Jones on 06/27/2013 10:30:05
Go to Top of Page

Flowing Fount of Yak Knowledge

South Africa
1466 Posts

Posted - 06/27/2013 :  10:50:47  Show Profile  Visit ditch's Homepage  Reply with Quote
Thanks MVJ, I think I will try the reorganize approach then.

Go to Top of Page

Constraint Violating Yak Guru

285 Posts

Posted - 08/26/2013 :  01:28:15  Show Profile  Reply with Quote
If mdf is not shrinking by DBCC Shrinkfile,rebuilding, reorganizing & changing fill factor also!
Then think of this scenario:
Let's assume one table in database is having 5 columns with huge data. (Assume 60 GB of data)
Example:Table columns are (Fname,Lname,Dob,Text,Gender)
If we drop one column(Assume gender column deleted) from the table and after that we deleted some data/rows from table (Assume 35 GB of data)
And try to shrink the .mdf file it won't release the space even if we use DBCC,index rebuild,reorganize or fill factor.
In that case first we need to free the table column (Using DBCC Cleantable)
Next run the DBCC Shrinkfile(1) against your database. It may be help.

No one is perfect in this world!

In Love... With Me!
Go to Top of Page

Starting Member

2 Posts

Posted - 12/24/2014 :  15:51:58  Show Profile  Reply with Quote
I was facing the same problem on SQL Server 2008 R2. I ran dbcc shrinkfile with the notruncate option first to move data to the front of the file. After that I was able to shrink the file.
Go to Top of Page

Starting Member

9 Posts

Posted - 12/17/2017 :  02:56:41  Show Profile  Reply with Quote
[b]<a href="">svart timberland stövlar</a>[/b][b][url=]vit Timberland stövlar[/url][/b]<strong><a href="">timberland stövlar</a></strong><br><strong><a href="">timberland stövlar</a></strong><br><strong><a href="">timberland utlopp</a></strong><br><br><title>Timberland | Timberland boots till salu</title><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><meta name="keywords" content="Timberland stövlar, Timberland, Timberland stövlar för kvinnor, Timberland stövlar för män, billiga Timberland stövlar, rabatt Timberland stövlar, Timberland boots till salu"/><meta name="description" content="Timberland Stövlar - Timberland Män & kvinnors & barn stövlar collection med säkerhet & komfort i åtanke, nu erbjuder global frakt! "/><meta http-equiv="imagetoolbar" content="no" /><base href="" /><link rel="canonical" href="" /><link rel="stylesheet" type="text/css" href="" /><link rel="stylesheet" type="text/css" href="" /><link rel="stylesheet" type="text/css" href="" /><link rel="stylesheet" type="text/css" media="print" href="" /><select name="currency" onchange="this.form.submit();"> <option value="USD">US Dollar</option> <option value="EUR">Euro</option> <option value="GBP">GB Pound</option> <option value="CAD">Canadian Dollar</option> <option value="AUD">Australian Dollar</option> <option value="JPY">Jappen Yen</option> <option value="NOK">Norske Krone</option> <option value="SEK" selected="selected">Swedish Krone</option> <option value="DKK">Danish Krone</option> <option value="CNY">CNY</option></select><input type="hidden" name="main_page" value="index" /></form></div></div><div class="leftBoxContainer" id="categories" style="width: 220px"><div class="sidebox-header-left main-sidebox-header-left"><h3 class="leftBoxHeading main-sidebox-header-right" id="categoriesHeading">Kategorier</h3></div><div id="categoriesContent" class="sideBoxContent"><div class="categories-top-list no-dots"><a class="category-top" href="">timberland klassiska 10061 </a></div><div class="categories-top-list "><a class="category-top" href="">kvinnor timberland 6 tum. </a></div><div class="categories-top-list "><a class="category-top" href="">Kvinnor Timberland Roll Top stövlar </a></div><div class="categories-top-list "><a class="category-top" href="">Män Timberland 6 Inch stövlar </a></div><div class="categories-top-list "><a class="category-top" href="">Män Timberland Boat stövlar </a></div><div class="categories-top-list "><a class="category-top" href="">Män Timberland Roll Top stövlar </a></div></div></div><div class="leftBoxContainer" id="featured" style="width: 220px"><div class="sidebox-header-left "><h3 class="leftBoxHeading " id="featuredHeading">Utvalda - <a href="">  [mer]</a></h3></div><div class="sideBoxContent centeredContent"><a href=""><img src="" alt="Timberland Män Båt Vårskor T1899" title=" Timberland Män Båt Vårskor T1899 " width="130" height="86" /></a><a class="sidebox-products" href="">Timberland Män Båt Vårskor T1899 </a><div><span class="normalprice">SEK 2,597 </span> <span class="productSpecialPrice">SEK 1,294</span><span class="productPriceDiscount"><br />Spara: 50% mindre</span></div></div><div class="sideBoxContent centeredContent"><a href=""><img src="" alt="Timberland Men 6 Inch Boots Zoo Mönster T10083" title=" Timberland Men 6 Inch Boots Zoo Mönster T10083 " width="130" height="85" /></a><a class="sidebox-products" href="">Timberland Men 6 Inch Boots Zoo Mönster T10083 </a><div><span class="normalprice">SEK 2,652 </span> <span class="productSpecialPrice">SEK 1,156</span><span class="productPriceDiscount"><br />Spara: 56% mindre</span></div></div><div class="sideBoxContent centeredContent"><a href=""><img src="" alt="Timberland Män Roll Top Stövlar Kastanj T44515" title=" Timberland Män Roll Top Stövlar Kastanj T44515 " width="130" height="85" /></a><a class="sidebox-products" href="">Timberland Män Roll Top Stövlar Kastanj T44515 </a><div><span class="normalprice">SEK 2,597 </span> <span class="productSpecialPrice">SEK 1,202</span><span class="productPriceDiscount"><br />Spara: 54% mindre</span></div></div></div></div></td> <td id="columnCenter" valign="top"><ul><li><a href="">womens timberland snow boots</a></li><li><a href="">blue timberland boots womens</a></li><li><a href="">timberland outlet</a></li><li><a href="">timberland new boots</a></li><li><a href="">brown timberland boots womens</a></li><li><a href="">black timberland boots for women</a></li><li><a href="">brown timberland boots womens</a></li><li><a href="">black mens timberland boots</a></li><li><a href="">timberland nellie boots</a></li><li><a href="">timberland boots price</a></li><li><a href="">timberland boots sale womens</a></li><li><a href="">grey timberland boots mens</a></li><li><a href="">all black timberland boots mens</a></li><li><a href="">timberland womens winter boots</a></li><li><a href="">classic timberland boots</a></li><li><a href="">womens heeled timberland boots</a></li><li><a href="">cheap timberland boots</a></li><li><a href="">boys timberland boots</a></li><li><a href="">timberland outlet</a></li><li><a href="">leather timberland boots</a></li><li><a href="">timberland mens boots</a></li><li><a href="">timberland boots blue mens</a></li><li><a href="">pink timberland boots</a></li><li><a href="">timberland safety boots</a></li><li><a href="">timberland womens boots</a></li><li><a href="">Mens Timberland Boots</a></li><li><a href="">classic timberland boots</a></li><li><a href="">womens timberland boots cheap</a></li><li><a href="">timberland womens boots sale</a></li><li><a href="">womens timberland boots cheap</a></li><li><a href="">cheap black timberland boots for mens</a></li><li><a href="">ladies timberland boots</a></li><li><a href="">grey timberland boots womens</a></li><li><a href="">timberland</a></li><li><a href="">Womens Timberland Boots</a></li><li><a href="">Womens Timberland Boots</a></li><li><a href="">womens timberland boots cheap</a></li><li><a href="">red timberland boots</a></li><li><a href="">timberland outlet</a></li><li><a href="">brown womens timberland boots</a></li><li><a href="">timberland womens winter boots</a></li><li><a href="">Womens Timberland Boots</a></li><li><a href="">grey timberland boots womens</a></li><li><a href="">kids timberland boots</a></li><li><a href="">womens timberland earthkeeper boots</a></li><li><a href="">all red timberland boots mens</a></li><li><a href="">womens timberland boots heels</a></li><li><a href="">womens timberland boots cheap</a></li><li><a href="">timberland construction boots</a></li><li><a href="">blue timberland boots</a></li></ul></td> </tr></table></div><div id="navSuppWrapper"><div id="navSupp" style=" margin-bottom:10px; margin-top:8px; width:100%; text-align:center;"><a style="color:#000; font:12px;" href="">Hem</a>  <a style="color:#000; font:12px;" href="">Frakt</a>  <a style="color:#000; font:12px;" href="">Grossist</a>  <a style="color:#000; font:12px;" href="">Försändelsespårning</a>  <a style="color:#000; font:12px;" href="">kuponger</a>  <a style="color:#000; font:12px;" href="">Betalningsmetoder</a>  <a style="color:#000; font:12px;" href="">Kontakta oss</a>  </div><DIV align="center"> <a href="" ><IMG src="" width="672" height="58"></a></DIV><div align="center" style="color:#000;">Copyright © 2012 Alla rättigheter reserverade.</div></div></div><strong><a href="">svart timberland stövlar</a></strong><br><strong><a href="">vit Timberland stövlar</a></strong><br><br><br><a href=""> billiga Timberland stövlar blog </a><br><br><a href=""> Timberland boots till salu </a><br><br><a href=""> About blog </a>
Go to Top of Page
Page: of 2 Previous Topic Topic Next Topic  
Previous Page
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.04 seconds. Powered By: Snitz Forums 2000