FIFO queue table for multiple workers in SQL Server
You need exactly 3 lock hints
- READPAST
- UPDLOCK
- ROWLOCK
I answered this previously on SO: https://stackoverflow.com/questions/939831/sql-server-process-queue-race-condition/940001#940001
As Remus says, using service broker is nicer but these hints do work
Your error about isolation level usually means replication or NOLOCK is involved.