Retired products

How SQL Lock works

SQL Lock creates a database named RedGate with the following objects:

Object nameObject typePurpose
[dbo].[LockedObjects]TableStores locks on objects
[dbo].[GetLockedObjects]Stored procedureRetrieves locked objects from [dbo].[LockedObjects]
[dbo].[IsObjectLocked]Stored procedureChecks if objects are locked
[dbo].[LockObject]Stored procedureLocks objects
[dbo].[UnlockObject]Stored procedureUnlocks objects
[RedGate_CheckForLockedObjectOnDDLChange]TriggerDetects when someone tries to modify a locked object

You can review the script to before you run it.

After the script runs, you can use the SQL Lock interface to lock and unlock objects, or lock objects manually by running SQL.


Didn't find what you were looking for?