1 2 | So you are looking for the last entry in a table for your database that has auto increment. Well I have this to share with you. Use the mysql_insert_id() function.
mysql_query("INSERT INTO table1 (product) values ('$somethin')"); $lastID = mysql_insert_id();
|
No comments:
Post a Comment