SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Shrinking a SQL Server Database


Shrinking a SQL Server Database

Author
Message
James Lindner
James Lindner
Forum Newbie
Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)

Group: General Forum Members
Points: 9 Visits: 37
I recently redid some of the schema in my database, normalizing data better. The database size was 110GB at the time that I did this. The data including indexes is now only 55 GB. I cannot get SQL Server to shrink the database back down to the 55 GB size(or even 60). Nothing I do will shrink the data files. The Initial Size of the database got set to 110 GB. Is there any way to reset the initial size of the database?
James Lindner
James Lindner
Forum Newbie
Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)Forum Newbie (9 reputation)

Group: General Forum Members
Points: 9 Visits: 37
I have already tried DBCC ShrinkFile and DBCC ShrinkDatabase with no luck. It basically only shrinks to the size of the Intial Size setting.
Steve Jones
Steve Jones
SSC Guru
SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)

Group: Administrators
Points: 279283 Visits: 19896
Can't go below original size, AFAIK.

Build a new db, script things out, xfer data.

Follow me on Twitter: @way0utwest
Forum Etiquette: How to post data/code on a forum to get the best help
My Blog: www.voiceofthedba.com
Steve Jones
Steve Jones
SSC Guru
SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)SSC Guru (279K reputation)

Group: Administrators
Points: 279283 Visits: 19896
And if you shrank the database, you might have caused a lot of fragmentation. Be sure you reindex.

Follow me on Twitter: @way0utwest
Forum Etiquette: How to post data/code on a forum to get the best help
My Blog: www.voiceofthedba.com
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum







































































































































































SQLServerCentral


Search