Update statement sent by PHP to MySQL
| From: | Andreas Pucko | Date: | Fri, 11 May 2001 17:24:07 +0000 |
| Subject: | Update statement sent by PHP to MySQL | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-52487@lists.php.net to get a copy of this message | ||
Hi there,
I am trying to update a row in my MySQL database (I am an newbie)
It does not work, but the DB does not return an error.
Is there an error in the syntax??
// Create the user record
//--------------------------------------------------------------------------
------------------------------
if (!($newresult = mysql_db_query($DB, "
update $T1
set
caption = $caption
where name = $name
")))
{
HEADER("Location:admin.php?content=edit_dataentry&errormsg=baduserrecord");
}
//--------------------------------------------------------------------------
------------------------------
Thanx for your help
Cheers
Andy