I want to fetch the last value generated from a query from database ,so I used following code.But I get 0 instead of the last value.So, please check this.I am new in PHP.Thanks in advance.

```
$feedbackStudentInfo="INSERT INTO `feedback_system_db`.`feedback_student_info` (`fs_id`, `batch_id`,`course`,`semester`, `section`, `feedback_session`)VALUES('','$feedBatchId','$course_id','$Current_Sem' ,'$Current_section',2014)";

$test2=mysqli_query($con,$feedbackStudentInfo);

$fsid=mysql_insert_id();

echo $fsid;

```