What kind of friends do I come to ask for your help, I am working on laravel 5.4 for some issues I have to execute a stored procedure that performs an insert and returns the id of the saved record, my question is how do I receive the id that returns the procedure after the insert so far only returns me true or false, it is worth mentioning that the database is in mysql.
$id = 'roman';
$pw = '9141186427';
$cod = '0';
$db = DB::connection();
$db = new PDO('mysql:host=localhost;dbname=servicios', "root", "");
$sql = $db->prepare('CALL insert_cliente ?, ?, ?');
$sql->bindParam(1, $id);
$sql->bindParam(2, $pw);
$sql->bindParam(3, $cod);
$sql->execute();