Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: B D Jensen <bjorn.d.jensen@xxxxxxxxx>
- Date: Fri, 14 Mar 2008 10:21:09 -0700 (PDT)
Hi Erland!
"And it
seems a very reasonable assumption that the only piece of code that
ever
will insert rows into myGroups is this procedure. "
YES, all create-access via this proc.
"you have created a serialization point"
So
SELECT @groupID = myGroupID
FROM myGroup WITH (UPDLOCK) -- select only for lock purpose
also "locks" myGroupMember?
I suppose it would not be enough to write:
select null WITH (UPDLOCK)
This is 1. time I heard about "application lock "
I found this example:
http://www.sqlteam.com/article/application-locks-or-mutexes-in-sql-server-2005
I suppose then I should use @LockMode = 'Update'
Thank you very much. I expect to update this tread at the end of this
month, after I have released a fix and jobs had run for a while,
then I can tell, it the problem go away i production also...
Best regards
Bjorn
.
- Follow-Ups:
- Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: Erland Sommarskog
- Re: concurrency problem with lists ("check constraint" on groups of rows)
- References:
- concurrency problem with lists ("check constraint" on groups of rows)
- From: B D Jensen
- Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: Erland Sommarskog
- Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: B D Jensen
- Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: Erland Sommarskog
- Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: B D Jensen
- Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: Erland Sommarskog
- Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: B D Jensen
- Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: Erland Sommarskog
- concurrency problem with lists ("check constraint" on groups of rows)
- Prev by Date: Triggers
- Next by Date: Re: concurrency problem with lists ("check constraint" on groups of rows)
- Previous by thread: Re: concurrency problem with lists ("check constraint" on groups of rows)
- Next by thread: Re: concurrency problem with lists ("check constraint" on groups of rows)
- Index(es):