August 22, 2008 at 3:19 am
Hi Guys,
I have a .mdf with 12GB, but only 1.7 GB with data, indexes...
When i run sp_spaceused:
database_name: BD
database_size: 12096.75 MB
unallocated space: 10395.03 MB
reserved: 1715744 KB
data: 1668048 KB
index_size: 22872 KB
unused: 24824 KB
I have run shrink file, UPDATEUSAGE, and nothing results...
how i can delete unallocated space ? (it's not log file...) , it's because i have 12.7 initial size data file 🙁
regards
August 22, 2008 at 3:28 am
1- Script offending database creation
2- Take a full backup
3- Drop your offending database
4- Delete mdf, ndf and ldf related datafiles.
5- Alter database creation script setting -perhaps - 2 Gig for mdf file
6- Create database by executing your altered database creation script
7- Restore database -force - from your full backup at step #2
8- Pay my $180 bill and be happy forever 😀
_____________________________________
Pablo (Paul) Berzukov
Author of Understanding Database Administration available at Amazon and other bookstores.
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.August 22, 2008 at 4:06 am
TRy This Commands:
DBCC shrinkfile (filename, expected size in MB , notruncate)
After Executing Above Next Step:
DBCC shrinkfile(filename, expected size in MB , truncateonly)
Hope your problem will solve.
regards
Manoj
August 22, 2008 at 4:13 am
shrinkfile not result... and restore not restults, database always keep same initial size 🙁
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply