SQL syntax

A

Anonymous

Guest
can anyone help me to edit to correct form?

$query="insert into book(buyer) values('".$x."')where id=".$book;
 
Code:
$query="INSERT INTO `book` (buyer) VALUES ('$x') WHERE `id`='$book'";
 
Back
Top