One suggestion I could give is maybe the update statement might be something like this:
"update my_table set foo="bar" where baz = $something"
If $something doesn't always get set to what it should be because of some rarely occurring conflict, for example, the update statement won't update anything. I suggest the following:
$query="update blah blah blah".
mysql_query($query);
file_put_contents('query.log', $query, FILE_APPEND | LOCK_EX);
This will log the query each time into query.log (make sure it's writable by the script). After a while look through and see if there are any query's with missing bits or whatever.