I am implementing doctrine in a project, however I have a question about inserting, updating and removing data. When I execute the following command for example:
$companyName = $entityManager->getRepository("Admin\Module\Configuration\Entity\Config")->findOneBy(array("type"=>"company_name"));
$companyName->setValue($POST["companyName"]);
$entityManager->persist($companyName);
$entityManager->flush();
How can I capture the doctrine result to see if it actually gave the persist and also successfully executed the flush? In case I could not get his return yet. I tried with try catch, but Exception always returns empty.
I wonder if there is anything like mysqli's affected_rows to use in doctrine