MySQL Forums
Forum List  »  PHP

ON DUPLICATE KEY fustrations
Posted by: deliverance1957
Date: April 14, 2006 10:48PM

I am trying to insert a new cell into my table but I keep getting an error saying it is wrong. So, can someone correct me?

code:
--------------------
$sql = "INSERT `pending` (name, lan, web, last_name,email )
VALUES ('$name', '$hostname', '$web', '$lastname', '$email')
ON DUPLICATE KEY UPDATE lan='$hostname' AND web='$web'";
--------------------

Options: ReplyQuote


Subject
Written By
Posted
ON DUPLICATE KEY fustrations
April 14, 2006 10:48PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.