MySQL gets the last id last_insert_id () function of the database
MySQL gets the last id of the database last_insert_id() function, use MySQL LAST_INSERT_ID function to get the value of the last insert ID generated by MySQL. 1, the use of the function mysql> SELECT LAST_INSERT_ID() as lastID; LAST_INSERT_ID function to get the sequence number of the last row inserted into the table. Article from: www.huthon.cn/