Re: concurrency problem with lists ("check constraint" on groups of rows)
- From: B D Jensen <bjorn.d.jensen@xxxxxxxxx>
- Date: Tue, 11 Mar 2008 22:17:21 -0700 (PDT)
Hi!
The purpose is to store lists so I later can make easy sql-exists
consctructs:
select * from T t where exists (select null from myGroupMember p where
p.id=t.id and p.myGroupID=@myGroupID)
The table myGroupMember will become as small as possible, since a list
only will be stored once.
The lists comes from user input, so I don't know them before.
The code above gives oppurtunity to make a FK's on myGroupID in other
tables!
=> analysis of which rows (in a new table A) uses the same group
become trivial!
And there is a reason for setting the isolation level: try to comment
out the lines with "SET..."
Both session complete returning different id's :-( Next time you run
call to proc with same input param it will result in
something like this: More than 1 myGroupID 121000,2000,3000,4000,5009,
Hope its now more clear what I want to achieve ;-)
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
- concurrency problem with lists ("check constraint" on groups of rows)
- Prev by Date: Result Row
- 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):