$insertsql=<<<EOT
insert into tb_manager values(null,‘$name‘,‘$pwd‘,‘1‘);
select @pid:=last_insert_id();//寻找最新插入记录ID并赋值给pid,pid进行传值
insert into tb_mastergroup values(null,@pid,‘$name‘,2,‘1‘,‘MR‘);
EOT;
$sql=mysql_query($insertsql);
时间: 2024-12-20 05:37:33