Subject Re: SELECT FOR UPDATE WITH LOCK and Connections
Author Adam
I should add:

> Is it different by design? Probably, MSSQL must poll the clients on a
> regular basis to know about this before the OS flags the connection as
> closed. The downside must be that brief outages would cause the
> connection to fail on MSSQL that would be simply resumed on Firebird.

There is actually another way where the 'over the wire protocol'
requires the client to send heartbeat messages every so often. If the
server does not receive a message within a tolerance, it assumes the
connection is broken. Of course this would be a lot more 'chatty',
imagine 500 clients broadcasting essentially meaningless messages to
the server every 30 seconds. At least the server could choose to only
poll the connections where there is a lock that someone is waiting
for. Anyhow, I am off topic.

Do you actually need to use the for update with lock syntax? MGA
allows other ways of solving most of these sorts of problems without
resorting to pessimistic locks.