sargento
asked on
IS a Double insert illegal?
Can you do something like this:
$result = mysql_query($sql,$connecti on) or die("Couldn't execute insert.");
$result2 = mysql_query($sql2,$connect ion) or die("Couldn't execute 2nd insert.");
If not is it possible to insert into 2 different tables in one statement?
$result = mysql_query($sql,$connecti
$result2 = mysql_query($sql2,$connect
If not is it possible to insert into 2 different tables in one statement?
ys...it is possible for inserting into 2 tables with one tables...
yes, you can - there is no way to insert into 2 tables with one SQL.
TIP: if you insert 2 records into the same table you can use
insert into TABLE (field1,field2) values (val1_1,val_2),(val2_1,val 2_2)
TIP: if you insert 2 records into the same table you can use
insert into TABLE (field1,field2) values (val1_1,val_2),(val2_1,val
ASKER
So it is legal to make to insertions in one right after the other like my example?
ASKER
So it is legal to make two insertions, one right after the other like my example?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.