I know that my question is related to transactions or tables lock, but I could not able to manage it. My PHP application has to select some values from a table then it has to loop through the results to update some values in the same result. I want the application to stop any user select when there is a select query is operating till the loop is completed.
I used lock tables write, but it prevented the application to do the update. My application is built on CakePHP 1.2.11.