Davor Cengija wrote:
> On Thu, 15 Jul 1999, A. Brandic wrote:
> >Just a query. Does Mysql support "row" level locking?
> >I've loocked in the manual but could not find anything and the TODO list
> >doeasn't say much (except database locking);
> Table locking (for reading or writing) is what you're looking
> for. Check the manual.
> Davor Cengija
You can simulate row locking by using a string lock comprised of the
table name plus the primary key value.
This does not actually lock anything in the table, but if your
applications adhere to this convention, you can get the same result
by always getting the lock before updating.
Beware, though. There is NO deadlock protection here, and you may only
hold one lock at a time.