1
0
mirror of synced 2024-12-14 23:26:04 +03:00

small refacory on AbstractEntityInheritancePersister

This commit is contained in:
Fabio B. Silva 2012-07-22 15:31:26 -03:00
parent e6f08f0b92
commit 7e348b7815

View File

@ -60,9 +60,12 @@ abstract class AbstractEntityInheritancePersister extends BasicEntityPersister
*/ */
protected function getSelectColumnSQL($field, ClassMetadata $class, $alias = 'r') protected function getSelectColumnSQL($field, ClassMetadata $class, $alias = 'r')
{ {
$tableAlias = $alias == 'r' ? '' : $alias;
$columnName = $class->columnNames[$field]; $columnName = $class->columnNames[$field];
$sql = $this->getSQLTableAlias($class->name, $alias == 'r' ? '' : $alias) . '.' . $this->quoteStrategy->getColumnName($field, $class, $this->platform);
$columnAlias = $this->getSQLColumnAlias($columnName); $columnAlias = $this->getSQLColumnAlias($columnName);
$sql = $this->getSQLTableAlias($class->name, $tableAlias) . '.'
. $this->quoteStrategy->getColumnName($field, $class, $this->platform);
$this->rsm->addFieldResult($alias, $columnAlias, $field, $class->name); $this->rsm->addFieldResult($alias, $columnAlias, $field, $class->name);
if (isset($class->fieldMappings[$field]['requireSQLConversion'])) { if (isset($class->fieldMappings[$field]['requireSQLConversion'])) {