I have a database in MySql with two columns, one where the user's name is stored and the user's corresponding value in the second column. How do I replace the values in the second column with new values? I am having trouble finding the answer in Google, because I am not so familiar with PHP. I know that both REPLACE and UPDATE functions are there, but I am having trouble getting them to work for only that specific user, not ALL the values in the column. The code I am unsuccessfully using is this:
$query1 = "UPDATE TextMeBabe SET '$username' = replace( '$username', '$existingcredits', '$newcredits')";
echo "Values added";
mysql_query($query1);
mysql_close();
(I am able to log into the database with no issues, so I have not provided that code)