How to: Delete Data or Log Files from a Database (SQL Server Management Studio)
SQL Server 2005
This topic describes how to delete data or log files from a database by using Object Explorer in SQL Server Management Studio.
Important: |
|---|
| A file must be empty before it can be deleted. For more information, see How to: Shrink a File (SQL Server Management Studio). |
-
In Object Explorer, connect to an instance of the SQL Server 2005 Database Engine and then expand that instance.
-
Expand Databases, right-click the database from which to delete the file, and then click Properties.
-
Select the Files page.
-
In the Database files grid, select the file to delete and then click Remove.
-
Click OK.
Tasks
How to: Shrink a Database (SQL Server Management Studio)How to: Add Data or Log Files to a Database (SQL Server Management Studio)
Concepts
Adding and Deleting Data and Transaction Log FilesOther Resources
Database Engine How-to TopicsIndexes How-to Topics

Important: