From 096bd90aed37dc7475d7f3f26f82d2bdee9f9200 Mon Sep 17 00:00:00 2001 From: Marco Pivetta Date: Sat, 17 Jan 2015 05:39:02 +0100 Subject: [PATCH] #1178 - using the `PersisterHelper` to extract type of associated meta-result columns --- lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php b/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php index f01d0a944..69691b9d3 100644 --- a/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php +++ b/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php @@ -1316,10 +1316,7 @@ class BasicEntityPersister implements EntityPersister $resultColumnName = $this->getSQLColumnAlias($joinColumn['name']); $columnList[] = $this->getSQLTableAlias($class->name, ($alias == 'r' ? '' : $alias) ) . '.' . $quotedColumn . ' AS ' . $resultColumnName; - - if (isset($targetClass->fieldNames[$joinColumn['referencedColumnName']])) { - $type = $targetClass->fieldMappings[$targetClass->fieldNames[$joinColumn['referencedColumnName']]]['type']; - } + $type = PersisterHelper::getTypeOfColumn($joinColumn['referencedColumnName'], $targetClass, $this->em); $this->rsm->addMetaResult($alias, $resultColumnName, $quotedColumn, $isIdentifier, $type); }