doctrine/DoctrineBundle — Issue #17: Refreshing an entity after disabling a filter has no effect
Author: Burgov
Created: 2012-01-30 15:22:56+00:00
State: open

The situation:

I have a Person with a 1-to-1 relation to User, fetch mode is EAGER. The user has a deleted flag, which in this case is set to true. The filter automatically adds a "deleted = 0" to the join query

I wish to fetch the user anyway, so I disable the filter and execute a refresh:

$em->getFilters()->disable('soft_delete');
$em->refresh($person);

Unfortunately, this doesn't work as the left join part of the query is saved line 971 through 973 in BasicEntityPersister:

```php
if ($this->_selectColumnListSql !== null) {
return $this->_selectColumnListSql;
}
```

if I remove these lines, everything works fine...