这是我试过的查询,
$result = "INSERT INTO task_assign(assigned_to,assigned_by,end_on,task_title,task_desc,priority,task_status,history_assigned) VALUES('$assignTo','$assignBy','$endOn','$title','$description','$priority','$status','$assignTo')";
mysql_query("INSERT INTO notification(title,description,priority,category_id,assignment_type,sender_id,receiver_id,date_time)
VALUES('$title', '$description', '$priority', '$category_id', '1', $assigassignTonBy, $assignTo, NOW())
");
//this return only task_assign
echo $rowId = mysql_insert_id();
如何从表中获取最后一个插入ID?