Everything is working down to the update query. I have the userid, I have the password, and then nothing happens.

PHP Code:
if ($p) { // If everything's OK.
         
echo $u.'<br />'; echo $p.'<br />'; ?this echos the correct information

    
// Make the query.
        
$query "UPDATE users_tbl SET pass = SHA('$p'+'salt') WHERE user_id='$u'";
         echo 
$query; echo '<br />';
         
$result mysql_query ($query) or trigger_error("Query: $query\n<br />MySQL Error: " mysql_error());

    if (
mysql_affected_rows() == 1) { // If it ran OK.
            // Send an email, if desired.
                
echo '<h3>Your password has been changed.</h3><br /><p>Return to <a href="/">home</a></p>';
                
$query3 "UPDATE users_tbl SET chng_pass=('no') WHERE user_id='$u'";
                
$result3 mysql_query ($query3) or trigger_error("Contact site administrator");
                } 
// end of the if it ran ok conditional
                  
// end of the if ($p) conditional 
I get the echo of userid and password. I get the echo of the query. The password does not change.

I suspect I have done something stupid, but I cannot see it.