By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,955 Members | 1,768 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,955 IT Pros & Developers. It's quick & easy.

Synchronization between threads

P: 1
My question is how to prevent a script in the PHP code to do its work until another thread finish working with another script (that it have)
Hint: I want to prevent any php page to access the database while another script updates values in that database.
Thank you
Feb 18 '12 #1
Share this Question
Share on Google+
2 Replies


helimeef
P: 77
If script1.php is waiting on script2.php, have script2.php call script1.php after it's done executing.
Mar 26 '12 #2

Dormilich
Expert Mod 5K+
P: 8,639
I want to prevent any php page to access the database while another script updates values in that database.
usually the database takes care of that itself by locking the table (row) in operation.
Mar 27 '12 #3

Post your reply

Sign in to post your reply or Sign up for a free account.