다음에 생성될 auto_increment 컬럼의 값 알아내기
테이블이름을 인자로 넣어주면...
다음에 생성될 auto_increment 컬럼의 값이 리턴 됩니다.
$변수 = get_autoinc("테이블이름");
function get_autoinc($table)
{
global $connect;
$data=mysql_fetch_array(mysql_query("show table status like '$table'"));
return $data[Auto_increment];
}
바로 입력된 auto_increment 컬럼 값
$no = mysql_insert_id();