tahir.nazir Posted June 19, 2009 Share Posted June 19, 2009 hican anybody tell me how can i get last inserted id from database (in prestashop)? Link to comment Share on other sites More sharing options...
rocky Posted June 20, 2009 Share Posted June 20, 2009 The last id of what? You could click on the down arrow under the ID header of a table in the Back Office and the last ID would be displayed first, or you could write a MySQL query on one of the Prestashop database tables to select the max ID. Link to comment Share on other sites More sharing options...
peorthyr Posted February 20, 2013 Share Posted February 20, 2013 in php, there is a function that does that: http://php.net/manual/en/function.mysql-insert-id.php hope it helps. 1 Link to comment Share on other sites More sharing options...
vekia Posted February 20, 2013 Share Posted February 20, 2013 peorthyr has got right you can use mysql_insert_id() for example: <?PHP $lastid=mysql_insert_id(); echo $lastid; ?> Link to comment Share on other sites More sharing options...
peorthyr Posted February 20, 2013 Share Posted February 20, 2013 (edited) sorry wrong post Edited February 20, 2013 by peorthyr (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts