Delete by Primary Key

admin

Administrator
Staff member
I am using PHP with MySql.

This statement does not work for me.

$result = mysql_query("delete from ksline1 where id = '$id'",$conn);

$id is my primary key
if I replace $id with any other field such as

$result = mysql_query("delete from ksline1 where company = '$company'",$conn);

it works.
 
Back
Top