[PHP-DB] Only Insert on Error?

2001-07-18 Thread Jeff Oien
I can't figure this out. The first code works as far as inserting into a MySQL database with the !result error checking. The second with the error code commented out doesn't. I can't figure out why. Jeff Oien if ($M_First_Name) { $sql = INSERT INTO $table_name (First_Name, Last_Name,

RE: [PHP-DB] Only Insert on Error?

2001-07-18 Thread Cami
Try using ' instead of \ like: if ($M_First_Name) { $sql = INSERT INTO $table_name (First_Name, Last_Name, Family_Position, Address, Address1, City, State, Zip, Email, Home_Phone, Work_Phone, Coop_Month, Timestamp) VALUES ('$M_First_Name', '$M_Last_Name', '$MatherFamilyPosition','$M_Address1',