Jump to content

[SOLVED] Locking Tables


coutts

Recommended Posts

Hello:

I have read a lot about "locking" tables. Really I can't make head nor tails of this and when and how it might be used. Nearest I might be able to understand is that this would be used when multiple users might be trying to add to or modify the table. Can anyone enlighten me

Link to comment
Share on other sites

ISAM table typles LOCK on INSERT/UPDATE/ALTERATIONS. Nature of the beast. That means no further queries can be issues against said ISAM TABLE until the process is complete.

 

This is the most common cause of sites getting deadlocked due to a huge queue of slow-running queries.

 

ISAM does Table-level locking.

InnoDB does row-level locking (Better)

Falcon (MySQL 6.0) does coordinate level locking (Bestesterester)

 

I think the new MySQL 6.0 Miriam (Replacement for ISAM) engine does row-level locking, too.

Link to comment
Share on other sites

If you think about it there is an extremely limited situation that causes an issue.

 

Like if an Admin is updating a product database and then someone attempts to place an order on you site the item price may be incorrect.

 

However properly written php and if needed innoDB can cover you

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.