|
Posted by Syl on 05/18/06 21:45
Hi group -
I am collecitng form data and inserting into multiple tables with a
foregin key.
Can someone tell me why if the insert fails on the 1st insert, then all
the other inserts also return a FAILURE return code :
$delegatecontent = array( "id" => $idnum, "language" => $insertlang );
$delegateres = pg_insert($conn, 'delegate', $delegatecontent);
if ($delegateres) { // echo "success del";
} else {
echo "<b>INSERT Failed!
}
$meetingcontent = array( "fk_meetingsid" => $idnum, "meetingsga" =>
$meetingga );
$meetingres = pg_insert($conn, 'meetings', $meetingcontent);
if ($meetingres) { // echo "success meetings";
} else {
echo "<b>INSERT Failed!
}
What is syntactically wrong with this code ?
THANKS!
Navigation:
[Reply to this message]
|