USE mydbname GO ALTER DATABASE mydbname Set Recovery Simple GO ALTER DATABASE mydbname Set Recovery Full GO DBCC SHRINKFILE ('mydbname_log', 1) GO
Computer, Technology, Databases, Google, Internet, Mobile, Linux, Microsoft, Open Source, Security, Social Media, Web Development, Business, Finance
Tuesday, May 17, 2011
Database Shrink MsSQL database log file
Many questions have been raised on the Internet on how to shrink the file size of a database log file. The following code snippet will do what is needed (replace mydbname with your database name).
Subscribe to:
Post Comments (Atom)
Popular Posts
-
I would like to apologize that sigining of my guestbook is not possible at the moment due to an unexpected bug. There is already 74 entries ...
-
Robocopy, short for "Robust File Copy" is an advanced command-line utility included in Windows. It's designed to copy files an...
-
*********** Try to sleep now, close your eyes Soon the birds would stop singing Twinkling stars, are shining bright They'll be watch...
-
Installed FortiClient recently but the challenge in disabling the application/service from running automatically on every start-up annoyed m...
-
Singapore's Land Transport Authority has just released an updated official MRT map including one additional station on the Downtown Line...
No comments:
Post a Comment
Do provide your constructive comment. I appreciate that.