January 18, 2002 at 7:15 am
Does anyone have any information on the usage of xp_userlock?
-Chris
January 18, 2002 at 4:35 pm
Nope, but a guess would be something related to sp_getapplock?
Andy
January 18, 2002 at 6:13 pm
All I've been able to determine thus far is that it has three mandatory parameters:
@subcommand
@resource
@dbid
K. Brian Kelley
http://www.sqlservercentral.com/columnists/bkelley/
K. Brian Kelley
@kbriankelley
January 21, 2002 at 2:06 pm
January 21, 2002 at 4:08 pm
I tried to execute the extended stored procedure in Query Analyzer and it gave the error saying xp_userlock requires parameter @subcommand and so on. Once I had put in values for each of the three parameters, it started giving me a different error (@resource requires a type nchar/nvarchar).
K. Brian Kelley
http://www.sqlservercentral.com/columnists/bkelley/
K. Brian Kelley
@kbriankelley
March 29, 2011 at 12:19 pm
Brian,
I know merge replication uses it to establish if another merge process is running for a particular subscription. The call within sp_getApplock had the following parameters.
0,
@dbid = <the ID of the DB>
@DBPrincipal = 'db_owner'
@resource = <item acquiring the lock. In my case the subscription>
@Mode = 5 --five stood for exclusive
@owner = 3 -- three stood for session
@locktimeout = 0
Hope this helps.
Hope things are well at Agfirst....
Doug K
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply