Please start any new threads on our new site at We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
Save Password
Forgot your Password?

 All Forums
 Site Related Forums
 Article Discussion
 Article: Application Locks (or Mutexes) in SQL Server 2005
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Ask SQLTeam Question

0 Posts

Posted - 01/07/2008 :  11:26:21  Show Profile  Visit AskSQLTeam's Homepage  Reply with Quote

Application locks aren't a well known area of locking in SQL Server, but they can be very useful for special
scenarios. They work in a analogous way to the lock() construct in .Net and
are basicaly user defined mutexes in SQL Server.

Read Application Locks (or Mutexes) in SQL Server 2005

Starting Member

1 Posts

Posted - 08/28/2009 :  19:36:24  Show Profile  Reply with Quote
Very good article. Very useful. I found that sp_getapplock will NOT work within a dotnet System.Transaction - even if it is also within a SQL transaction. It took me a while to figure that out.
Go to Top of Page

Cybernetic Yak Master

11752 Posts

Posted - 11/24/2010 :  16:29:33  Show Profile  Visit spirit1's Homepage  Reply with Quote
define won't work. the sp_getapplock lock does NOT lock data. only blocks of code.

Causing trouble since 1980
Speed up SSMS development: <- version 1.9 out!

SQL Server MVP
Go to Top of Page
  Previous Topic Topic Next Topic  
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2019 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.02 seconds. Powered By: Snitz Forums 2000