FaaPz/PDO

lastinsertid removed?

sickness0666 opened this issue · 2 comments

has lastInsertId() been removed?

using the new documentation and have used the:

$insertId = $insertStatement->execute()->lastInsertId();

and get method not found

kwhat commented

Yes and the docs are incorrect, it should be:

if ($insert->execute()) {
    $insertId = $database->lastInsertId();
}
kwhat commented

Should be resolved in the docs. Let me know if there are any other questions or issues.