Inferring id's field types
This commit is contained in:
parent
af3591fbca
commit
4ef0a238bf
@ -345,9 +345,12 @@ class BasicEntityPersister implements EntityPersister
|
|||||||
. ' WHERE ' . implode(' = ? AND ', $identifier) . ' = ?';
|
. ' WHERE ' . implode(' = ? AND ', $identifier) . ' = ?';
|
||||||
|
|
||||||
$types = [];
|
$types = [];
|
||||||
foreach ($identifier as $fieldName) {
|
foreach ($id as $field => $value) {
|
||||||
$types[] = $versionedClass->fieldMappings[$fieldName]['type'];
|
foreach ($this->getTypes($field, $value, $versionedClass) as $type) {
|
||||||
|
$types[] = $type;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$flatId = $this->identifierFlattener->flattenIdentifier($versionedClass, $id);
|
$flatId = $this->identifierFlattener->flattenIdentifier($versionedClass, $id);
|
||||||
|
|
||||||
$value = $this->conn->fetchColumn($sql, array_values($flatId), 0, $types);
|
$value = $this->conn->fetchColumn($sql, array_values($flatId), 0, $types);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user