Shrink Method

SQLServer.Database Object

Description

Reduces the space allocated to a database

Visual Basic

Database.Shrink ( [NewSizeInMB :=] lNewSizeInMB )

C++

HRESULT pDatabase->Shrink ( long lNewSizeInMB );

Elements

Element Type Description

lNewSizeInMB Long New size of the database in megabytes

Reference

DBCC SHRINKDB