Actions

JDatabase/insertid

From Joomla! Documentation

$newId = $dbaseConnection->insertid();

// returns the automatic id number generated by the most recent insert query, very handy..