Microsoft® SQL Server™ 2005 Administrator's Companion
by Edward Whalen, Marcilina Garcia, Burzin Patel, Stacia Misner, Victor Isakov
Deleting a Database
A database can be deleted via SQL Sever Management Studio, or via the DROP DATABASE command. Listed below are some important points to consider when dropping a database:
A database cannot be deleted if it is in use.
Dropping a database deletes the database from an instance of SQL Server and deletes the physical disk files used by the database. The only exception is when the database or any one of the files is offline. In this case, the disk files are not deleted and must be deleted manually from the file system.
A database can be deleted regardless of its state: offline, read-only, suspect, and so on. However, once deleted it can be re-created only by restoring a backup.
Only users having CONTROL permission on the database can ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access