Re: How to bring down a database
From: David Portas (REMOVE_BEFORE_REPLYING_dportas_at_acm.org)
Date: 07/08/04
- Next message: Karan: "How to reduce timeouts in SQL Server?"
- Previous message: Quentin Ran: "Re: How to bring down a database"
- In reply to: Linda: "How to bring down a database"
- Next in thread: Hari Prasad: "Re: How to bring down a database"
- Reply: Hari Prasad: "Re: How to bring down a database"
- Reply: anonymous_at_discussions.microsoft.com: "Re: How to bring down a database"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 8 Jul 2004 23:11:53 +0100
Assuming you have already logged out or killed all user processes you can
take the DB offline as follows:
EXEC sp_dboption 'DATABASE_NAME', 'offline', 'TRUE'
Perhaps more useful is to make the database single-user only:
USE DATABASE_NAME
EXEC sp_dboption 'DATABASE_NAME', 'single user', 'TRUE'
-- David Portas SQL Server MVP --
- Next message: Karan: "How to reduce timeouts in SQL Server?"
- Previous message: Quentin Ran: "Re: How to bring down a database"
- In reply to: Linda: "How to bring down a database"
- Next in thread: Hari Prasad: "Re: How to bring down a database"
- Reply: Hari Prasad: "Re: How to bring down a database"
- Reply: anonymous_at_discussions.microsoft.com: "Re: How to bring down a database"
- Messages sorted by: [ date ] [ thread ]