Re: Been staring at the code for too long...
| From: | Dan Shirah | Date: | Fri, 09 Jan 2009 19:06:38 +0000 |
| Subject: | Re: Been staring at the code for too long... | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-285887@lists.php.net to get a copy of this message | ||
>
> mysqli_stmt_prepare($stmt, "UPDATE database.table (
> FName, LName, email, phone,
> url, record,
> subscribed, date,
> IPAddress, Business,
> Address1, City, State,
> Zip,
> Coffee, Meeting,
> areaPlans)
> VALUES
> (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)");
>
>
> Warning: mysqli_stmt_bind_param() [function.mysqli-stmt-bind-param]:
> invalid object or resource mysqli_stmt in /public_html/purl/purlprocess.php
> on line 67
> You have an error in your SQL syntax; check the manual that corresponds to
> your MySQL server version for the right syntax to use near '( FName, LName,
> email, phone, url, recor' at line 1
>
> Am I just going crazy or is there something really wrong?
>
> Okay.. I'm done... First stupid question of the year... Only 3,349,587 more
> to go for the year! :P
I don't work with MySQL, but shouldn't the UPDATE syntax be something like
this:
mysqli_stmt_prepare($stmt, "UPDATE database.table SET
FName = ?,
LName = ?,
email = ?,
phone = ?
WHERE id = ?");