I want to be able to create a group of records at a time and ensure that the identifier field is continuous for the group (without interruptions because someone else logs in and creates the record while it is in the process). I assume that some kind of lock table will work, but I am not a sql guru, so any advice would be appreciated (what type of lock? Any possible problems? Etc.).
For a small background, the table structure is quite simple ...
TABLE PropertyCode
(
Code INT IDENTITY,
UserID INT
)
The property code is assigned to the property in the property table. Property codes can be reused (they are printed on characters, and characters can rotate between multiple properties). It is much cheaper to print a continuous sequence of numbers than random numbers on signs.
source
share