I created an eck entity in relation with a node with 2 entity reference fields :
- node > entity reference field to eck entity (n target_id)
- eck entity > entity référence field to node (1 target_id)
I added a relation with the cer module (eck <> node) and this error appears when creating an eck entity (programmatically like with the eck admin ui):
Recoverable fatal error: Object of class Entity could not be converted to string in DatabaseStatementBase->execute() (line 2171 of /includes/database/database.inc).
After having swapped them (node <> eck), it's seems to work well.
I'm a little confused because the order of the cardinality does not seem to matter on cer (eg. bidirectional option) and I don't think that is the explaination.
It's not my first problem with cer+eck and I have a doubt about the compatibility of the two modules in certain conditions to be determined (or 3 modules if entity reference is a part of the problem when synchronizing eck and nodes with entity references via cer).
An idea of the origin of the problem ?
Nb: Similar error appears in this cer issue comment, maybe in relation, but not from the same cause: https://www.drupal.org/node/1345264#comment-5854460
Comments
Comment #1
corentin.crouvisier commented