j152 Posted June 19, 2008 Share Posted June 19, 2008 Hi all ... I have been fighting with a database and losing.... I get no error messages, but my database table will not update... // count rows & divide $result = mysql_query("SELECT * FROM sample"); $num_row = mysql_num_rows($result); $adjustment = $old_total / $num_row; //update databse $query = "UPDATE sample SET total = $adjustment WHERE boxes=9"; Any help would be greatly appreciated. Quote Link to comment Share on other sites More sharing options...
j152 Posted June 19, 2008 Author Share Posted June 19, 2008 Solved I added mysql_query($query); Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.