Here is a snip of my code
 
$query = "SELECT Count FROM COUNTER_Page_Views WHERE Counter_ID = '" .
$count_id . "' FOR UPDATE";
$query1 = "UPDATE COUNTER_Page_Views SET Count = Count + 1 WHERE
Counter_ID = '" . $count_id . "'";
$result = mysql_query($query);
$result1 = mysql_query($query1);
 
what is happeneing is that seesion are colliding in between these
queries, I need to somehow single thread this section of code. Is that
possible? MySQL says that you can lock rows for updating but it only
seems to work when the queries are in the same code block, not when
executed separately. Anyone have a solution to making an update to a
record without having other users make an update in the middle of a
different users' process?
 
Matt Babineau
Freelance Internet Developer
e:  <mailto:[EMAIL PROTECTED]>
[EMAIL PROTECTED] 
p: 603.943.4237
w:  <http://www.illuminatistudios.com/> http://www.illuminatistudios.com
 
 


Reply via email to