Fast way to take DB offline/online


A fast way to kill all connections to a DB before restoring it.

ALTER DATABASE >
SET OFFLINE WITH ROLLBACK IMMEDIATE

ALTER DATABASE >
SET ONLINE

Comments

Popular posts from this blog

Execute and access code restricted internals as a partner or customer

Expressions in query ranges

Removing duplicate records