I use a kind of snippet code like this
foreach($contacts as $contact){
$db_stmt = $this->db->prepare("EXECUTE stpFoo '', '', ?, ?");
//... operation code
}
When I arrive around 700 contacts, the $db_stmt is null. I suppose my Sql Server database is busy, and I guess i should raise the timeout for connection. I'm asking if somebody already has this error to look for the best solution.
Did not find it in the stack heap...
Thanks for reading ;).
Ps: it is not a duplicate, as the database is sql-server and I already put
$this->db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
The error is displayed below.