Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Stored Procedure Help Please 1

Status
Not open for further replies.

Savil

Programmer
Apr 28, 2003
333
EU
Hi
I have a stored procedure that manipulates a lot of records and takes a while to run. How can I make so only one person can run it at any one time?

Thanks
 
Create a table with a InUse column

As the first step of the sp code check to see if this has a value of 0, if so then the sp is ok to run.
Next change the value to 1 to prevent anyone else being able to run the sp

Remember to change the value back to 0 at the end of the sp
 
FANTASTIC IDEA!!!!!!!!!!!!!

Thanks again
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top