Locking mysql tables with php


Posted on 16th Feb 2014 07:03 pm by admin

Hi

BACKGROUND:
I have multiple instances of the same php script running in a WAMP environment. The script contains mysql queries to lock certain tables in the database. I'm getting some very odd behaviour which would seem to suggest that the locks are not working, and that one instance of the script is reading from a table that another instance of the script should have a write lock on.

ACTUAL QUESTION:
Do two instances of the same php script running through WAMP get totally independent locks on tables in a database?

I didn't post this question in the mysql forum because although it is about locking tables, it is about locking tables from the point of view of a php script. Please move it if I have posted in the wrong forum.

Cheers

Paul

No comments posted yet

Your Answer:

Login to answer
348 Like 52 Dislike
Previous forums Next forums
Other forums

The type or namespace name 'ServiceModel' does not exist in the namespace 'System'
When I locally run the website, it works just fine, but when I uploaded it to the hosting environmen

phpMailer will not connect using SMTP
I am trying to use phpMailer with smtp:

Code: [Select]$mailer = new PHPMailer();
$mailer-&

IP Logger for Voting Script
Can anybody help me place an IP logger into my voting script?
I know that maybe it is not as secu

PHP hyperlinks generator
Hi

I need some help to get this done using php:


1 - I have few hyperlinks say 500

why aint this working?
i have this code:

Code: $num = 250;
$count = ($num - $rcount);

echo $rc

Preserving user-entered linebreaks
Hi, I'm building a web 2.0 thingy from scratch and I wanna display text which users input. It's all

user administration
Dear @all,

what I have to do to set the user defaults for new users. At the moment I woul

weird problem
last time, i did post a topic concerning why my page sometime will load as blank page when using IE.

Error when call dll from oracle
Hi all, please help me!

I have dll write C language, I want call it from oracle procedur

couldn't connect to your database
Hello I am new to php mysql

Actually i have read A tutorial on nettuts
"http://net.tu

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash