PDA

View Full Version : mySQL and LOCK TABLES


tagarciap
10-10-2006, 06:41 PM
I have a website which uses PHP and MySQL. However Im not sure when I explicitly needs to control concurrenct access to the database using LOCK TABLES. For example, there is an auction section on the site where users bid on an item, and here I do. But do I really need to do this everywhere? Say for example, just inserting to or updating a contactDetails table?

guelphdad
10-10-2006, 08:18 PM
you don't even necessarily need to lock your tables. you could use auto increment field to get data from one table and insert it to a secondary table. you can also use transactions.