O'Reilly logo

Microsoft SQL Server 2012 Internals by Bob Beauchemin Kalen Delaney Conor Cunningham, Jonathan Kehayias, Benjamin Nevarez, and Paul S. Randal

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Expanding or shrinking a database

You can expand and shrink databases automatically or manually. The mechanism for automatic expansion is completely different from the mechanism for automatic shrinkage. Manual expansion is also handled differently from manual shrinkage. Log files have their own rules for growing and shrinking, as covered in Chapter 5.

Warning

Shrinking a database or any data file is an extremely resource-intensive operation, so don’t do it unless you absolutely must reclaim disk space. Shrinking a data file can also lead to excessive logical fragmentation within your database, as discussed in Chapter 7.

Automatic file expansion

Expansion can happen automatically to any one of the database’s files when that particular file becomes ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required