Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Singleton selects and status updates

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2001-07-30 : 08:52:11
Tom writes "I am trying to implement a work queue approach to scheduling jobs between multiple processes. I want to create a stored procedure that will poll the work queue table and return a row with a valid status and then update the status to "in process".

So I need to perform a select that will return only 1 row and I need to lock this row so another process cannot get it. I also have to update the row.

Any help is appreciated,
Tom"
   

- Advertisement -