Jira issue originally created by user mridgway:
I haven't fully investigated this, but doing an update on trunk today I started receiving the following error message:
Catchable fatal error: Argument 1 passed to Doctrine\DBAL\Connection::_bindTypedValues() must implement interface Doctrine\DBAL\Driver\Statement, instance of PDOStatement given, called in ./library/Doctrine/DBAL/Connection.php on line 639 and defined in ./library/Doctrine/DBAL/Connection.php on line 869
This is occurring when a row is updated to point to the related field in another row (when both are persisted at the same time). It doesn't actually break the updates (with xdebug installed anyway).
It only appears to occur with a select few of my models that contain cascaded persists (and I'll be sure to attempt a test case for this for tomorrow). I haven't tested this fully but wanted to post this in case anyone has an idea of why this might be happening.
Comment created by romanb:
Hm, are you creating the PDO instance yourself (and passing it to Doctrine via the 'pdo' option)? That might be the reason.
I'm not sure whether we should just remove the typehint and use duck-typing there or whether we should enforce a better way.
Comment created by mridgway:
Yes, we are passing a PDO instance to Doctrine.
Should be fixed now. The method in question now uses duck-typing.
Issue was closed with resolution "Fixed"