Skip to content

Loading…

DDC-485: Doctrine\DBAL\Connection::_bindTypedValues() must implement interface Doctrine\DBAL\Driver\Statement #4989

Closed
doctrinebot opened this Issue · 5 comments

1 participant

@doctrinebot

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.

@doctrinebot

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.

@doctrinebot

Comment created by romanb:

I'm not sure whether we should just remove the typehint and use duck-typing there or whether we should enforce a better way.

@doctrinebot

Comment created by mridgway:

Yes, we are passing a PDO instance to Doctrine.

@doctrinebot

Comment created by romanb:

Should be fixed now. The method in question now uses duck-typing.

@doctrinebot

Issue was closed with resolution "Fixed"

@doctrinebot doctrinebot added this to the 2.0-BETA1 milestone
@doctrinebot doctrinebot closed this
@doctrinebot doctrinebot added the Bug label
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.