List:General Discussion« Previous MessageNext Message »
From:David Lerer Date:March 17 2014 6:07pm
Subject:Locking a Database (not tables)
View as plain text  
Frequently, we import a production dump that contains only 1 or 2 databases into one of our QA instances that contains many more databases. (i.e. "database" being a "schema" or a "catalogue).
At the beginning of the import script, we first drop all objects in the QA database so that it will be a perfect match (object wise) to production.

Is there an easy way to lock the whole database for the duration of the import - so that no developers can update the database?
Obviously, I can revoke permissions, but I was wondering whether there is a better approach.

Thanks, David.

David Lerer | Director, Database Administration | Interactive | 605 Third Avenue, 12th Floor, New York, NY 10158
Direct: (646) 487-6522 | Fax: (646) 487-1569 | dlerer@stripped | www.univision.net

The information contained in this e-mail and any attached 
documents may be privileged, confidential and protected from 
disclosure.  If you are not the intended recipient you may not 
read, copy, distribute or use this information.  If you have 
received this communication in error, please notify the sender 
immediately by replying to this message and then delete it 
from your system.
Thread
Locking a Database (not tables)David Lerer21 Mar 2014