I am trying to update a table based on a mysql query of another table in the same database. I can use
$con = mysql_connect("server","database","%*&^(*&(*&");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
mysql_select_db("database", $con);
mysql_query("UPDATE data SET Column_name = 'Value'
WHERE column_name = **value in another table** ");
mysql_close($con);
?>
to change the value based on a set value i put in the code. But does anyone know what I should do to get the value to be based on a query of another table?
thanks
2007-03-26
12:34:00
·
2 answers
·
asked by
billinfenway
1
in
Computers & Internet
➔ Programming & Design